Package org.apache.derby.client
Class ClientXAConnection
java.lang.Object
org.apache.derby.client.ClientPooledConnection
org.apache.derby.client.ClientXAConnection
- All Implemented Interfaces:
PooledConnection
,XAConnection
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate NetXAConnection
private boolean
private Connection
private NetXAResource
private static int
private XAResource
Fields inherited from class org.apache.derby.client.ClientPooledConnection
logWriter_, netXAPhysicalConnection_, physicalConnection_, rmId_
-
Constructor Summary
ConstructorsConstructorDescriptionClientXAConnection
(BasicClientDataSource40 ds, LogWriter logWtr, String userId, String password) -
Method Summary
Methods inherited from class org.apache.derby.client.ClientPooledConnection
addConnectionEventListener, addStatementEventListener, finalize, informListeners, isStatementPoolingEnabled, nullLogicalConnection, onStatementClose, onStatementErrorOccurred, recycleConnection, removeConnectionEventListener, removeStatementEventListener
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface javax.sql.PooledConnection
addConnectionEventListener, addStatementEventListener, removeConnectionEventListener, removeStatementEventListener
-
Field Details
-
rmIdSeed_
private static int rmIdSeed_ -
xares_
-
netXares_
-
fFirstGetConnection_
private boolean fFirstGetConnection_ -
logicalCon_
-
controlCon_
-
-
Constructor Details
-
ClientXAConnection
public ClientXAConnection(BasicClientDataSource40 ds, LogWriter logWtr, String userId, String password) throws SQLException - Throws:
SQLException
-
-
Method Details
-
getConnection
Description copied from class:ClientPooledConnection
Creates a logical connection.This is the standard API for getting a logical connection handle for a pooled connection. No "resettable" properties are passed, so user, password, and all other properties may not change.
- Specified by:
getConnection
in interfacePooledConnection
- Overrides:
getConnection
in classClientPooledConnection
- Throws:
SQLException
- if creating a new logical connection fails
-
getUnigueRmId
private static int getUnigueRmId() -
getRmId
public int getRmId() -
getXAResource
- Specified by:
getXAResource
in interfaceXAConnection
- Throws:
SQLException
-
close
Description copied from class:ClientPooledConnection
Closes the physical connection to the data source and frees all associated resources.- Specified by:
close
in interfacePooledConnection
- Overrides:
close
in classClientPooledConnection
- Throws:
SQLException
- if closing the connection causes an error. Note that this connection can still be considered closed even if an error occurs.
-