Package com.im.df.api.util
Class EntityDataIterator
- java.lang.Object
-
- com.im.df.api.util.EntityDataIterator
-
- All Implemented Interfaces:
java.util.Iterator
public class EntityDataIterator extends java.lang.Object implements java.util.IteratorAllows to iterate over large sets of data.TODO P2 - this class might be removed from API
- Author:
- Tim Dudgeon
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description classEntityDataIterator.Entry
-
Constructor Summary
Constructors Constructor Description EntityDataIterator(DFEntityDataProvider edp, DFTermExpression query, java.util.Set<? extends DFField> fields, int chunkSize, com.im.commons.progress.DFEnvironmentRO env)Creates a new instance of EntityDataIterator.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected java.util.List<? extends java.lang.Comparable<?>>getIds()booleanhasNext()EntityDataIterator.Entrynext()voidremove()intsize()protected java.util.List<? extends java.lang.Comparable<?>>subList(java.util.List<? extends java.lang.Comparable<?>> list, int start)
-
-
-
Constructor Detail
-
EntityDataIterator
public EntityDataIterator(DFEntityDataProvider edp, DFTermExpression query, java.util.Set<? extends DFField> fields, int chunkSize, com.im.commons.progress.DFEnvironmentRO env)
Creates a new instance of EntityDataIterator.- Parameters:
edp- The data provider for the entity whose data we wantquery- A query to filter the data. Can be null.fields- Interested fields.chunkSize- The number of data items that are retrieved in one go. When all items in the chunk have been iterated through the next chunk will be retrieved.env- The DFEnvironmentRO- Since:
- 15.6.22
-
-
Method Detail
-
size
public int size()
-
hasNext
public boolean hasNext()
- Specified by:
hasNextin interfacejava.util.Iterator
-
next
public EntityDataIterator.Entry next()
- Specified by:
nextin interfacejava.util.Iterator
-
remove
public void remove()
- Specified by:
removein interfacejava.util.Iterator
-
getIds
protected java.util.List<? extends java.lang.Comparable<?>> getIds()
-
subList
protected java.util.List<? extends java.lang.Comparable<?>> subList(java.util.List<? extends java.lang.Comparable<?>> list, int start)
-
-