Package net.sf.basedb.core
Class FastAnnotationLoader.FastIterator<T>
java.lang.Object
net.sf.basedb.core.FastAnnotationLoader.FastIterator<T>
- All Implemented Interfaces:
Iterator<FastAnnotationLoader.FastAnnotation<T>>
- Enclosing class:
- FastAnnotationLoader<T>
static class FastAnnotationLoader.FastIterator<T> extends Object implements Iterator<FastAnnotationLoader.FastAnnotation<T>>
Iterator implementation that splits the query into multiple calls depending
on the max number of parameters that can be used in a query.
-
Field Summary
-
Constructor Summary
Constructors Constructor Description FastIterator(DbControl dc, AnnotationType annotationType, Item itemType, int projectId, boolean includeDefault, List<Integer> itemIds)
-
Method Summary
Modifier and Type Method Description boolean
hasNext()
FastAnnotationLoader.FastAnnotation<T>
next()
private boolean
nextIterator()
Create a new query that load annotations for items between startIndex and endIndex.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface java.util.Iterator
forEachRemaining, remove
-
Field Details
-
dc
-
sql
-
itemIds
-
maxParameters
private final int maxParameters -
it
-
startIndex
private int startIndex -
endIndex
private int endIndex -
next
-
-
Constructor Details
-
FastIterator
FastIterator(DbControl dc, AnnotationType annotationType, Item itemType, int projectId, boolean includeDefault, List<Integer> itemIds)
-
-
Method Details
-
nextIterator
private boolean nextIterator()Create a new query that load annotations for items between startIndex and endIndex.- Returns:
- TRUE if an iterator was created, FALSE if not
-
hasNext
public boolean hasNext() -
next
-