Package org.alfresco.repo.search
Class AbstractResultSetRowIterator
java.lang.Object
org.alfresco.repo.search.AbstractResultSetRowIterator
- All Implemented Interfaces:
Iterator<ResultSetRow>,ListIterator<ResultSetRow>,ResultSetRowIterator
- Direct Known Subclasses:
ChildAssocRefResultSetRowIterator,DBResultSetRowIterator,SolrJSONResultSetRowIterator,SortedResultSetRowIterator
Iterate over the rows in a ResultSet
- Author:
- andyh
-
Constructor Summary
ConstructorsConstructorDescriptionAbstractResultSetRowIterator(ResultSet resultSet) Create an iterator over the result set. -
Method Summary
Modifier and TypeMethodDescriptionvoidadd(ResultSetRow o) booleanDoes the result set allow reversal?Get the underlying result setbooleanhasNext()booleanprotected intprotected intabstract ResultSetRownext()intabstract ResultSetRowprevious()intvoidremove()voidset(ResultSetRow o) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface java.util.Iterator
forEachRemaining
-
Constructor Details
-
AbstractResultSetRowIterator
Create an iterator over the result set. Follows stadard ListIterator conventions- Parameters:
resultSet- ResultSet
-
-
Method Details
-
getResultSet
Description copied from interface:ResultSetRowIteratorGet the underlying result set- Specified by:
getResultSetin interfaceResultSetRowIterator- Returns:
- - the result set
-
hasNext
public boolean hasNext()- Specified by:
hasNextin interfaceIterator<ResultSetRow>- Specified by:
hasNextin interfaceListIterator<ResultSetRow>
-
allowsReverse
public boolean allowsReverse()Description copied from interface:ResultSetRowIteratorDoes the result set allow reversal?- Specified by:
allowsReversein interfaceResultSetRowIterator- Returns:
- - true if the result set can be navigated in reverse.
-
hasPrevious
public boolean hasPrevious()- Specified by:
hasPreviousin interfaceListIterator<ResultSetRow>
-
next
- Specified by:
nextin interfaceIterator<ResultSetRow>- Specified by:
nextin interfaceListIterator<ResultSetRow>
-
moveToNextPosition
protected int moveToNextPosition() -
previous
- Specified by:
previousin interfaceListIterator<ResultSetRow>
-
moveToPreviousPosition
protected int moveToPreviousPosition() -
nextIndex
public int nextIndex()- Specified by:
nextIndexin interfaceListIterator<ResultSetRow>
-
previousIndex
public int previousIndex()- Specified by:
previousIndexin interfaceListIterator<ResultSetRow>
-
remove
public void remove()- Specified by:
removein interfaceIterator<ResultSetRow>- Specified by:
removein interfaceListIterator<ResultSetRow>
-
set
- Specified by:
setin interfaceListIterator<ResultSetRow>
-
add
- Specified by:
addin interfaceListIterator<ResultSetRow>
-