This class was introduced to share code between the pre-JDBC 4 and the JDBC 4+ versions of the JDBC classes.
The pattern for the prepareX methods is:
| Modifier and Type | Field and Description |
|---|---|
| private final JDBCStatementCache | cache
Statement cache for the associated physical connection. |
| private boolean | connCloseInProgress
Tells if this interactor is in the process of shutting down. |
| private final ArrayList | openLogicalStatements
List of open logical statements created by this cache interactor. |
| private final ClientConnection | physicalConnection
The underlying physical connection. |
| Access | Constructor and Description |
|---|---|
| pack-priv | StatementCacheInteractor(JDBCStatementCache
statement cache cache, ClientConnection associated physical connection physicalConnection)Creates a new JDBC statement cache interactor. |
| Modifier and Type | Method and Description |
|---|---|
| pack-priv synchronized void | |
| private CallableStatement | Returns: A logical callable statement.the underlying physical callable statement cs, StatementKey the statement key for the physical statement stmtKey)Creates a logical callable statement. |
| private PreparedStatement | Returns: A logical prepared statement.the underlying physical prepared statement ps, StatementKey the statement key for the physical statement stmtKey)Creates a logical prepared statement. |
| pack-priv JDBCStatementCache | |
| pack-priv synchronized void | markClosed(LogicalStatementEntity
the logical statement being closed logicalStmt)Designates the specified logical statement as closed. |
| pack-priv synchronized CallableStatement | |
| pack-priv synchronized CallableStatement | |
| pack-priv synchronized CallableStatement | |
| pack-priv synchronized PreparedStatement | |
| pack-priv synchronized PreparedStatement | |
| pack-priv synchronized PreparedStatement | |
| pack-priv synchronized PreparedStatement |
| cache | back to summary |
|---|---|
| private final JDBCStatementCache cache Statement cache for the associated physical connection. | |
| connCloseInProgress | back to summary |
|---|---|
| private boolean connCloseInProgress Tells if this interactor is in the process of shutting down. If this is true, it means that the logical connection is being closed. | |
| openLogicalStatements | back to summary |
|---|---|
| private final ArrayList<LogicalStatementEntity> openLogicalStatements List of open logical statements created by this cache interactor. | |
| physicalConnection | back to summary |
|---|---|
| private final ClientConnection physicalConnection The underlying physical connection. Note that it is the responsibility of the logical statement assoiciated with this cache interactor to ensure the interactor methods are not invoked if the logical statement has been closed. | |
| StatementCacheInteractor | back to summary |
|---|---|
| pack-priv StatementCacheInteractor(JDBCStatementCache cache, ClientConnection physicalConnection) Creates a new JDBC statement cache interactor.
| |
| closeOpenLogicalStatements | back to summary |
|---|---|
| pack-priv synchronized void closeOpenLogicalStatements() throws SQLException Closes all open logical statements created by this cache interactor. A cache interactor is bound to a single (caching) logical connection.
| |
| createLogicalCallableStatement | back to summary |
|---|---|
| private CallableStatement createLogicalCallableStatement(CallableStatement cs, StatementKey stmtKey) throws SQLException Creates a logical callable statement.
| |
| createLogicalPreparedStatement | back to summary |
|---|---|
| private PreparedStatement createLogicalPreparedStatement(PreparedStatement ps, StatementKey stmtKey) throws SQLException Creates a logical prepared statement.
| |
| getCache | back to summary |
|---|---|
| pack-priv JDBCStatementCache getCache() Returns the associated statement cache.
| |
| markClosed | back to summary |
|---|---|
| pack-priv synchronized void markClosed(LogicalStatementEntity logicalStmt) Designates the specified logical statement as closed.
| |
| prepareCall | back to summary |
|---|---|
| pack-priv synchronized CallableStatement prepareCall(String sql) throws SQLException | |
| prepareCall | back to summary |
|---|---|
| pack-priv synchronized CallableStatement prepareCall(String sql, int resultSetType, int resultSetConcurrency) throws SQLException | |
| prepareCall | back to summary |
|---|---|
| pack-priv synchronized CallableStatement prepareCall(String sql, int resultSetType, int resultSetConcurrency, int resultSetHoldability) throws SQLException | |
| prepareStatement | back to summary |
|---|---|
| pack-priv synchronized PreparedStatement prepareStatement(String sql) throws SQLException | |
| prepareStatement | back to summary |
|---|---|
| pack-priv synchronized PreparedStatement prepareStatement(String sql, int resultSetType, int resultSetConcurrency) throws SQLException | |
| prepareStatement | back to summary |
|---|---|
| pack-priv synchronized PreparedStatement prepareStatement(String sql, int resultSetType, int resultSetConcurrency, int resultSetHoldability) throws SQLException | |
| prepareStatement | back to summary |
|---|---|
| pack-priv synchronized PreparedStatement prepareStatement(String sql, int autoGeneratedKeys) throws SQLException | |