org.infinispan.query
Interface QueryIterator

All Superinterfaces:
Iterator<Object>, ListIterator<Object>
All Known Implementing Classes:
AbstractIterator, DistributedIterator, DistributedLazyIterator, EagerIterator, LazyIterator

public interface QueryIterator
extends ListIterator<Object>

Iterates over query results

Author:
Manik Surtani, Navin Surtani

Method Summary
 void afterFirst()
          Jumps to the one-after-the-first result
 void beforeLast()
          Jumps to the one-before-the-last result
 void close()
          This method must be called on your iterator once you have finished so that Lucene resources can be freed up.
 void first()
          Jumps to the first result
 boolean isAfterFirst()
           
 boolean isBeforeLast()
           
 boolean isFirst()
           
 boolean isLast()
           
 void jumpToResult(int index)
          Jumps to a specific index in the iterator.
 void last()
          Jumps to the last result
 
Methods inherited from interface java.util.ListIterator
add, hasNext, hasPrevious, next, nextIndex, previous, previousIndex, remove, set
 

Method Detail

jumpToResult

void jumpToResult(int index)
                  throws IndexOutOfBoundsException
Jumps to a specific index in the iterator.

Parameters:
index - index to jump to.
Throws:
IndexOutOfBoundsException - if the index is out of bounds

first

void first()
Jumps to the first result


last

void last()
Jumps to the last result


afterFirst

void afterFirst()
Jumps to the one-after-the-first result


beforeLast

void beforeLast()
Jumps to the one-before-the-last result


isFirst

boolean isFirst()
Returns:
true if the current result is the first

isLast

boolean isLast()
Returns:
true if the current result is the last

isAfterFirst

boolean isAfterFirst()
Returns:
true if the current result is one after the first

isBeforeLast

boolean isBeforeLast()
Returns:
true if the current result is one before the last

close

void close()
This method must be called on your iterator once you have finished so that Lucene resources can be freed up.


-->

Copyright © 2012 JBoss, a division of Red Hat. All Rights Reserved.