Class StatementCache.CachedStatement
- java.lang.Object
-
- org.apache.tomcat.jdbc.pool.interceptor.StatementDecoratorInterceptor.StatementProxy<java.sql.PreparedStatement>
-
- org.apache.tomcat.jdbc.pool.interceptor.StatementCache.CachedStatement
-
- All Implemented Interfaces:
java.lang.reflect.InvocationHandler
- Enclosing class:
- StatementCache
protected class StatementCache.CachedStatement extends StatementDecoratorInterceptor.StatementProxy<java.sql.PreparedStatement>
Proxy for a cached prepared statement.
-
-
Field Summary
-
Fields inherited from class org.apache.tomcat.jdbc.pool.interceptor.StatementDecoratorInterceptor.StatementProxy
closed, delegate
-
-
Constructor Summary
Constructors Constructor Description CachedStatement(java.sql.PreparedStatement parent, java.lang.String sql)Constructs a CachedStatement.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidcloseInvoked()Called when the close method is invoked on the statement.voidforceClose()Forces immediate closure of this cached statement.org.apache.tomcat.jdbc.pool.interceptor.StatementCache.CacheKeygetCacheKey()Returns the cache key for this statement.voidsetCacheKey(org.apache.tomcat.jdbc.pool.interceptor.StatementCache.CacheKey cacheKey)Sets the cache key for this statement.-
Methods inherited from class org.apache.tomcat.jdbc.pool.interceptor.StatementDecoratorInterceptor.StatementProxy
getActualProxy, getConnection, getConstructor, getDelegate, getSql, invoke, setActualProxy, setConnection, setConstructor, toString
-
-
-
-
Method Detail
-
closeInvoked
public void closeInvoked()
Description copied from class:StatementDecoratorInterceptor.StatementProxyCalled when the close method is invoked on the statement.- Overrides:
closeInvokedin classStatementDecoratorInterceptor.StatementProxy<java.sql.PreparedStatement>
-
forceClose
public void forceClose()
Forces immediate closure of this cached statement.
-
getCacheKey
public org.apache.tomcat.jdbc.pool.interceptor.StatementCache.CacheKey getCacheKey()
Returns the cache key for this statement.- Returns:
- the cache key
-
setCacheKey
public void setCacheKey(org.apache.tomcat.jdbc.pool.interceptor.StatementCache.CacheKey cacheKey)
Sets the cache key for this statement.- Parameters:
cacheKey- the cache key
-
-