com.agimatec.sql.query
Interface JdbcResultBuilder

All Known Implementing Classes:
ArrayResultBuilder, ColumnCommentBuilder, ColumnDescriptionBuilder, ConstraintCommentBuilder, ForeignKeyDescriptionBuilder, IndexDescriptionBuilder, PrimaryKeyDescriptionBuilder, SequenceDescriptionBuilder, StringResultBuilder, TableCommentBuilder

public interface JdbcResultBuilder


Method Summary
 void afterExecute(java.sql.ResultSetMetaData data, java.lang.Object queryObject, java.util.List resultList)
          The init() method is called once after the SQL statement has been executed and the result set is known.
 void close(boolean isComplete)
          The close() method is invoked, just BEFORE all associated resources (e.g. resultSet) are closed by the caller.
 void fetch(java.sql.ResultSet row)
          This method is invoked each time the cursor in the resultset is moved to the next row, as long as the resultList contains less objects than the client expects.
 

Method Detail

afterExecute

void afterExecute(java.sql.ResultSetMetaData data,
                  java.lang.Object queryObject,
                  java.util.List resultList)
                  throws java.sql.SQLException
The init() method is called once after the SQL statement has been executed and the result set is known.

Parameters:
data - JDBC result set meta data.
resultList - The List where the result objects are added to.
Throws:
java.sql.SQLException

fetch

void fetch(java.sql.ResultSet row)
           throws java.sql.SQLException
This method is invoked each time the cursor in the resultset is moved to the next row, as long as the resultList contains less objects than the client expects.

This method is expected to the following: - use the values of the row to create some object - might put the object to the resultList

DO NOT: invoke next() or any method that moves the resultSet cursor or closes the resultSet.

Parameters:
row - the ResultSet where the cursor is located on the current row
Throws:
java.sql.SQLException

close

void close(boolean isComplete)
           throws java.sql.SQLException
The close() method is invoked, just BEFORE all associated resources (e.g. resultSet) are closed by the caller. The close() method is the last callback to the visitor that allows to add pending results to the result list and to close own resources.

Throws:
java.sql.SQLException


Copyright © 2008-2012. All Rights Reserved.