public static class SqlStatement.MyDelegatingInvocationHandler extends DelegatingInvocationHandler
ResultSet interface by routing method
 calls to the result set inside a SqlStatement.
 When the result set is closed, so is the SqlStatement, and hence the
 JDBC connection and statement also.| Constructor and Description | 
|---|
SqlStatement.MyDelegatingInvocationHandler(SqlStatement sqlStatement)
Creates a MyDelegatingInvocationHandler. 
 | 
| Modifier and Type | Method and Description | 
|---|---|
void | 
close()
Helper method to implement  
ResultSet.close(). | 
protected Object | 
getTarget()
Returns the object to forward method calls to, should the derived class
 not implement the method. 
 | 
invokeSqlStatement.MyDelegatingInvocationHandler(SqlStatement sqlStatement)
sqlStatement - SQL statementprotected Object getTarget() throws InvocationTargetException
DelegatingInvocationHandlerThe default implementation returns null, which will cause the
 DelegatingInvocationHandler.invoke(Object, java.lang.reflect.Method, Object[]) method
 to throw an UnsupportedOperationException if the derived class
 does not have the required method.
getTarget in class DelegatingInvocationHandlerInvocationTargetException - if there is an error acquiring the
 targetpublic void close()
           throws SQLException
ResultSet.close().SQLException - on error