|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.metamatrix.common.connection.ManagedConnection com.metamatrix.common.connection.jdbc.JDBCMgdResourceConnection
public class JDBCMgdResourceConnection
Nested Class Summary |
---|
Nested classes/interfaces inherited from class com.metamatrix.common.connection.ManagedConnection |
---|
ManagedConnection.ConnectionStatistics |
Field Summary |
---|
Fields inherited from class com.metamatrix.common.connection.ManagedConnection |
---|
DATABASE, DRIVER, PASSWORD, PROTOCOL, USERNAME |
Constructor Summary | |
---|---|
JDBCMgdResourceConnection(java.util.Properties env,
java.lang.String userName)
Create a new instance of a JDBC connection. |
Method Summary | |
---|---|
protected void |
closeConnection()
This method is invoked by the pool to notify the specialized class that the connection is to be terminated. |
java.sql.Connection |
getConnection()
Create the JDBC connection that is being managed. |
protected void |
openConnection()
This method is invoked by the pool to notify the specialized class that the connection is to be established. |
protected void |
performCommit()
Make all changes made since the previous commit/rollback permanent, and release any data source locks currently held by the Connection. |
protected void |
performRollback()
Make all changes made since the previous commit/rollback permanent, and release any data source locks currently held by the Connection. |
protected void |
prepareForRead()
Prepare this connection for read-only transactions. |
protected void |
prepareForWrite()
Prepare this connection for write transactions. |
Methods inherited from class com.metamatrix.common.connection.ManagedConnection |
---|
close, commit, finalize, getEnvironment, getStats, getUserName, open, rollback, setForRead, setForWrite, setUserName |
Methods inherited from class java.lang.Object |
---|
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public JDBCMgdResourceConnection(java.util.Properties env, java.lang.String userName)
env
- the environment properties for the new connection.Method Detail |
---|
public java.sql.Connection getConnection()
protected void openConnection() throws ManagedConnectionException
openConnection
in class ManagedConnection
ManagedConnectionException
- if there is an error establishing the connection.protected void closeConnection() throws ManagedConnectionException
closeConnection
in class ManagedConnection
ManagedConnectionException
- if there is an error terminating the connection.protected void prepareForRead() throws ManagedConnectionException
prepareForRead
in class ManagedConnection
ManagedConnectionException
- if an error occurred within or during communication with this connection.protected void prepareForWrite() throws ManagedConnectionException
prepareForWrite
in class ManagedConnection
ManagedConnectionException
- if an error occurred within or during communication with this connection.protected void performCommit() throws ManagedConnectionException
performCommit
in class ManagedConnection
ManagedConnectionException
- if an error occurred within or during communication with this connection.protected void performRollback() throws ManagedConnectionException
performRollback
in class ManagedConnection
ManagedConnectionException
- if an error occurred within or during communication with this connection.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |