Package org.postgresql.ds
Class PGPooledConnection.StatementHandler
- java.lang.Object
-
- org.postgresql.ds.PGPooledConnection.StatementHandler
-
- All Implemented Interfaces:
java.lang.reflect.InvocationHandler
- Enclosing class:
- PGPooledConnection
private class PGPooledConnection.StatementHandler extends java.lang.Object implements java.lang.reflect.InvocationHandler
Instead of declaring classes implementing Statement, PreparedStatement, and CallableStatement, which would have to be updated for every JDK rev, use a dynamic proxy to handle all calls through the Statement interfaces. This is the part that requires JDK 1.3 or higher, though JDK 1.2 could be supported with a 3rd-party proxy package.The StatementHandler is required in order to return the proper Connection proxy for the getConnection method.
-
-
Field Summary
Fields Modifier and Type Field Description private PGPooledConnection.ConnectionHandler
con
private java.sql.Statement
st
-
Constructor Summary
Constructors Constructor Description StatementHandler(PGPooledConnection.ConnectionHandler con, java.sql.Statement st)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.Object
invoke(java.lang.Object proxy, java.lang.reflect.Method method, java.lang.Object[] args)
-
-
-
Field Detail
-
con
private PGPooledConnection.ConnectionHandler con
-
st
private java.sql.Statement st
-
-
Constructor Detail
-
StatementHandler
StatementHandler(PGPooledConnection.ConnectionHandler con, java.sql.Statement st)
-
-