|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.ddlutils.platform.ModelBasedResultSetIterator
public class ModelBasedResultSetIterator
This is an iterator that is specifically targeted at traversing result sets.
If the query is against a known table, then SqlDynaBean
instances
are created from the rows, otherwise normal DynaBean
instances
are created.
Constructor Summary | |
---|---|
ModelBasedResultSetIterator(PlatformImplBase platform,
Database model,
java.sql.ResultSet resultSet,
Table[] queryHints,
boolean cleanUpAfterFinish)
Creates a new iterator. |
Method Summary | |
---|---|
void |
advance()
Advances the iterator without materializing the object. |
void |
cleanUp()
Closes the resources (connection, statement, resultset). |
protected void |
finalize()
|
boolean |
hasNext()
|
boolean |
isConnectionOpen()
Determines whether the connection is still open. |
java.lang.Object |
next()
|
void |
remove()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ModelBasedResultSetIterator(PlatformImplBase platform, Database model, java.sql.ResultSet resultSet, Table[] queryHints, boolean cleanUpAfterFinish) throws DatabaseOperationException
platform
- The platformmodel
- The database modelresultSet
- The result setqueryHints
- The tables that were queried in the query that produced the given result set
(optional)cleanUpAfterFinish
- Whether to close the statement and connection after finishing
the iteration, upon on exception, or when this iterator is garbage collected
DatabaseOperationException
Method Detail |
---|
public boolean hasNext() throws DatabaseOperationException
hasNext
in interface java.util.Iterator
DatabaseOperationException
public java.lang.Object next() throws DatabaseOperationException
next
in interface java.util.Iterator
DatabaseOperationException
public void advance()
next()
except that no object is created and nothing is read from the result set.
public void remove() throws DatabaseOperationException
remove
in interface java.util.Iterator
DatabaseOperationException
public void cleanUp()
protected void finalize() throws java.lang.Throwable
finalize
in class java.lang.Object
java.lang.Throwable
public boolean isConnectionOpen()
true
if the connection is still open
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |