PooledConnection. The DisposableConnectionFacade intercepts
two methods:
java.sql.Connection#close() - returns the connection to the
pool then breaks the link between cutoff and the next interceptor.
May be called multiple times.java.lang.Object#toString() - returns a custom string for this
objectPoolConfiguration#setUseEquals(boolean) has been called with a
true argument.
| Access | Constructor and Description |
|---|---|
| protected |
| Modifier and Type | Method and Description |
|---|---|
| public boolean | equals(Object
the reference object with which to compare. obj)Overrides java. Indicates whether some other object is "equal to" this one. |
| public int | |
| public Object | invoke(Object
the proxy instance that the method was invoked on proxy, Method the method, Object[] Method instance corresponding to
the interface method invoked on the proxy instance. The declaring
class of the Method object will be the interface that
the method was declared in, which may be a superinterface of the
proxy interface that the proxy class inherits the method through.an array of objects containing the values of the
arguments passed in the method invocation on the proxy instance,
or args)null if interface method takes no arguments.
Arguments of primitive types are wrapped in instances of the
appropriate primitive wrapper class, such as
java.lang.Integer or java.lang.Boolean.Overrides org. Implements java. Gets invoked each time an operation on |
| public void | reset(ConnectionPool
- the connection pool owning the connection parent, PooledConnection - the pooled connection con)Implements abstract org. 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. |
| DisposableConnectionFacade | back to summary |
|---|---|
| protected DisposableConnectionFacade(JdbcInterceptor interceptor) | |
| equals | back to summary |
|---|---|
| public boolean equals(Object obj) Overrides java. Doc from java. Indicates whether some other object is "equal to" this one.
The
An equivalence relation partitions the elements it operates on into equivalence classes; all the members of an equivalence class are equal to each other. Members of an equivalence class are substitutable for each other, at least for some purposes. | |
| hashCode | back to summary |
|---|---|
| public int hashCode() Overrides java. Doc from java. Returns a hash code value for this object. This method is
supported for the benefit of hash tables such as those provided by
The general contract of
| |
| invoke | back to summary |
|---|---|
| public Object invoke(Object proxy, Method method, Object[] args) throws Throwable Overrides org. Implements java. Doc from org. Gets invoked each time an operation on
| |
| reset | back to summary |
|---|---|
| public void reset(ConnectionPool parent, PooledConnection con) Implements abstract org. Doc from org. 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.
| |