|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.googlecode.jdbw.util.ExecuteResultHandlerAdapter
public class ExecuteResultHandlerAdapter
This is a convenience class that implements ExecuteResultHandler and provides a default method implementation for this interface. You can then override only the methods that you care about.
| Constructor Summary | |
|---|---|
ExecuteResultHandlerAdapter()
|
|
| Method Summary | |
|---|---|
int |
getMaxRowsToFetch()
This method is called just before the query is sent to the database, setting the property on the Statement which limits the number of rows we want back. |
boolean |
nextResultSet()
This method is called in a multi result set query after one result set have been read and another one is coming. |
boolean |
nextRow(Object[] row)
The callback is called once for every row returned by a result set. |
void |
onDone()
This method is called when all processing of the query is done and the statement is about to be closed. |
void |
onGeneratedKey(Object object)
When a key has been generated on the server by the query, this callback is called with that value |
void |
onResultSet(List<String> columnNames,
List<Integer> columnTypes)
This callback is invoked when a new result set is read from the server, if the result set contains any rows they will appear in subsequent calls to the nextRow(Object[] row) callback. |
void |
onUpdateCount(int updateCount)
Callback called for queries that updated rows |
void |
onWarning(SQLWarning warning)
Callback called for every SQLWarning the server sent for the query |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ExecuteResultHandlerAdapter()
| Method Detail |
|---|
public int getMaxRowsToFetch()
ExecuteResultHandler
getMaxRowsToFetch in interface ExecuteResultHandlerpublic boolean nextResultSet()
ExecuteResultHandler
nextResultSet in interface ExecuteResultHandlerpublic boolean nextRow(Object[] row)
ExecuteResultHandler
nextRow in interface ExecuteResultHandlerrow - All the values of the row
public void onDone()
ExecuteResultHandler
onDone in interface ExecuteResultHandlerpublic void onGeneratedKey(Object object)
ExecuteResultHandler
onGeneratedKey in interface ExecuteResultHandlerobject - Generated key value
public void onResultSet(List<String> columnNames,
List<Integer> columnTypes)
ExecuteResultHandler
onResultSet in interface ExecuteResultHandlercolumnNames - List of all column namescolumnTypes - List of all column types (see java.sql.Types)public void onUpdateCount(int updateCount)
ExecuteResultHandler
onUpdateCount in interface ExecuteResultHandlerupdateCount - Number of rows affected by the query, as reported by
the serverpublic void onWarning(SQLWarning warning)
ExecuteResultHandler
onWarning in interface ExecuteResultHandlerwarning - SQLWarning from the server
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||