docs: public static DataSetIterator getIterator(Object o) {
          if (o instanceof DataSetIterator)
              return (DataSetIterator) o;
          else if (o instanceof DataSetIteratorFactory) {
              DataSetIteratorFactory factory = (DataSetIteratorFactory) o;
              return factory.create();
          }
  
          throw new IllegalArgumentException("Type must either be DataSetIterator or DataSetIteratorFactory");
      }