public class DisposableConnectionFacade extends JdbcInterceptor
PooledConnection. The DisposableConnectionFacade intercepts
two methods:
Connection.close() - returns the connection to the
pool then breaks the link between cutoff and the next interceptor.
May be called multiple times.Object.toString() - returns a custom string for this
objectPoolConfiguration.setUseEquals(boolean) has been called with a
true argument.CLOSE_VAL, EQUALS_VAL, GETCONNECTION_VAL, HASHCODE_VAL, ISCLOSED_VAL, ISVALID_VAL, ISWRAPPERFOR_VAL, properties, TOSTRING_VAL, UNWRAP_VAL| Modifier | Constructor and Description |
|---|---|
protected |
DisposableConnectionFacade(JdbcInterceptor interceptor) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(java.lang.Object obj) |
int |
hashCode() |
java.lang.Object |
invoke(java.lang.Object proxy,
java.lang.reflect.Method method,
java.lang.Object[] args)
Gets invoked each time an operation on
Connection is invoked. |
void |
reset(ConnectionPool parent,
PooledConnection con)
Gets called each time the connection is borrowed from the pool
This means that if an interceptor holds a reference to the connection
the interceptor can be reused for another connection.
|
compare, compare, disconnected, getNext, getProperties, isUseEquals, poolClosed, poolStarted, setNext, setProperties, setUseEqualsprotected DisposableConnectionFacade(JdbcInterceptor interceptor)
public void reset(ConnectionPool parent, PooledConnection con)
JdbcInterceptorreset in class JdbcInterceptorparent - - the connection pool owning the connectioncon - - the pooled connectionpublic int hashCode()
hashCode in class java.lang.Objectpublic boolean equals(java.lang.Object obj)
equals in class java.lang.Objectpublic java.lang.Object invoke(java.lang.Object proxy,
java.lang.reflect.Method method,
java.lang.Object[] args)
throws java.lang.Throwable
JdbcInterceptorConnection is invoked.
invoke in interface java.lang.reflect.InvocationHandlerinvoke in class JdbcInterceptorjava.lang.ThrowableCopyright © 2000-2019 Apache Software Foundation. All Rights Reserved.