code: public static DoubleIterator of(final Supplier<? extends DoubleIterator> iteratorSupplier) {
          N.checkArgNotNull(iteratorSupplier, "iteratorSupplier");
  
          return new DoubleIterator() {
              private DoubleIterator iter = null;
              private boolean isInitialized = false;
  
              @Override
              public boolean hasNext() {
                  if (isInitialized == false) {
                      init();
                  }
  
                  return iter.hasNext();
              }
  
              @Override
              public double nextDouble() {
                  if (isInitialized == false) {
                      init();
                  }
  
                  return iter.nextDouble();
              }
  
              private void init() {
                  if (isInitialized == false) {
                      isInitialized = true;
                      iter = iteratorSupplier.get();
                  }
              }
          };
      }
docs: Lazy evaluation.
  
  @param iteratorSupplier
  @return