Class PooledConnectionComponentInstance<P extends PooledConnection>
java.lang.Object
org.smallmind.persistence.sql.pool.PooledConnectionComponentInstance<P>
- All Implemented Interfaces:
EventListener,ConnectionEventListener,Existential,ComponentInstance<P>
public class PooledConnectionComponentInstance<P extends PooledConnection>
extends Object
implements ComponentInstance<P>, ConnectionEventListener
-
Constructor Summary
ConstructorsConstructorDescriptionPooledConnectionComponentInstance(ComponentPool<P> componentPool, P pooledConnection) PooledConnectionComponentInstance(ComponentPool<P> componentPool, P pooledConnection, String validationQuery) -
Method Summary
Modifier and TypeMethodDescriptionvoidclose()voidconnectionClosed(ConnectionEvent connectionEvent) voidconnectionErrorOccurred(ConnectionEvent connectionEvent) serve()booleanvalidate()
-
Constructor Details
-
PooledConnectionComponentInstance
-
PooledConnectionComponentInstance
public PooledConnectionComponentInstance(ComponentPool<P> componentPool, P pooledConnection, String validationQuery) throws SQLException - Throws:
SQLException
-
-
Method Details
-
getExistentialStackTrace
- Specified by:
getExistentialStackTracein interfaceExistential
-
validate
public boolean validate()- Specified by:
validatein interfaceComponentInstance<P extends PooledConnection>
-
connectionClosed
- Specified by:
connectionClosedin interfaceConnectionEventListener
-
connectionErrorOccurred
- Specified by:
connectionErrorOccurredin interfaceConnectionEventListener
-
serve
- Specified by:
servein interfaceComponentInstance<P extends PooledConnection>
-
close
- Specified by:
closein interfaceComponentInstance<P extends PooledConnection>- Throws:
SQLException
-