2.17.2: 2011-06-17

net.sf.basedb.core
Class ScrollIterator<E>

java.lang.Object
  extended by net.sf.basedb.core.ScrollIterator<E>
All Implemented Interfaces:
Iterator<E>

 class ScrollIterator<E>
extends Object
implements Iterator<E>

This is an iterator view of the result from a query using the Hibernate ScrollableResults object.

Version:
2.0
Author:
Nicklas
Last modified
$Date: 2009-04-06 14:52:39 +0200 (Mon, 06 Apr 2009) $

Field Summary
private  Class<E> dataClass
           
private  boolean isClosed
           
private  E nextElement
           
private  org.hibernate.ScrollableResults results
           
 
Constructor Summary
ScrollIterator(Class<E> dataClass, org.hibernate.ScrollableResults results)
           
 
Method Summary
 void close()
          Close the results and return resources.
 boolean hasNext()
           
 boolean isClosed()
          Check if the results has been closed.
 E next()
           
 void remove()
          Not supported.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

dataClass

private final Class<E> dataClass

results

private final org.hibernate.ScrollableResults results

isClosed

private boolean isClosed

nextElement

private E nextElement
Constructor Detail

ScrollIterator

ScrollIterator(Class<E> dataClass,
               org.hibernate.ScrollableResults results)
Method Detail

hasNext

public boolean hasNext()
Specified by:
hasNext in interface Iterator<E>

next

public E next()
Specified by:
next in interface Iterator<E>

remove

public void remove()
Not supported.

Specified by:
remove in interface Iterator<E>
Throws:
UnsupportedOperationException - Always

close

public void close()
Close the results and return resources.


isClosed

public boolean isClosed()
Check if the results has been closed.


2.17.2: 2011-06-17