public abstract class AbstractJdbc23PooledConnection
extends java.lang.Object
PGConnectionPoolDataSource| Constructor and Description |
|---|
AbstractJdbc23PooledConnection(java.sql.Connection con,
boolean autoCommit,
boolean isXA)
Creates a new PooledConnection representing the specified physical
connection.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addConnectionEventListener(javax.sql.ConnectionEventListener connectionEventListener)
Adds a listener for close or fatal error events on the connection
handed out to a client.
|
void |
close()
Closes the physical database connection represented by this
PooledConnection.
|
protected abstract javax.sql.ConnectionEvent |
createConnectionEvent(java.sql.SQLException e) |
java.sql.Connection |
getConnection()
Gets a handle for a client to use.
|
void |
removeConnectionEventListener(javax.sql.ConnectionEventListener connectionEventListener)
Removes a listener for close or fatal error events on the connection
handed out to a client.
|
public AbstractJdbc23PooledConnection(java.sql.Connection con,
boolean autoCommit,
boolean isXA)
public void addConnectionEventListener(javax.sql.ConnectionEventListener connectionEventListener)
public void removeConnectionEventListener(javax.sql.ConnectionEventListener connectionEventListener)
public void close()
throws java.sql.SQLException
java.sql.SQLExceptionpublic java.sql.Connection getConnection()
throws java.sql.SQLException
According to the JDBC 2.0 Optional Package spec (6.2.3), only one client may have an active handle to the connection at a time, so if there is a previous handle active when this is called, the previous one is forcibly closed and its work rolled back.
java.sql.SQLExceptionprotected abstract javax.sql.ConnectionEvent createConnectionEvent(java.sql.SQLException e)