org.openmdx.kernel.application.container.spi.sql
Class ManagedDatabaseConnection
java.lang.Object
org.openmdx.kernel.application.container.spi.sql.ManagedDatabaseConnection
- All Implemented Interfaces:
- ManagedConnection, CloseCallback
public class ManagedDatabaseConnection
- extends Object
- implements ManagedConnection, CloseCallback
Managed Database Connection
ManagedDatabaseConnection
public ManagedDatabaseConnection(ManagedConnectionFactory managedConnectionFactory,
XAConnection xaConnection)
throws ResourceException
- Constructor
- Throws:
ResourceException
getConnection
public Object getConnection(Subject subject,
ConnectionRequestInfo connectionRequestInfo)
throws ResourceException
- Specified by:
getConnection in interface ManagedConnection
- Throws:
ResourceException
destroy
public void destroy()
throws ResourceException
- Specified by:
destroy in interface ManagedConnection
- Throws:
ResourceException
cleanup
public void cleanup()
throws ResourceException
- Specified by:
cleanup in interface ManagedConnection
- Throws:
ResourceException
associateConnection
public void associateConnection(Object connection)
throws ResourceException
- Specified by:
associateConnection in interface ManagedConnection
- Throws:
ResourceException
postClose
public void postClose(Object connection)
- Description copied from interface:
CloseCallback
- To tell that an object has been closed.
- Specified by:
postClose in interface CloseCallback
- Parameters:
connection - the object which has been closed.
addConnectionEventListener
public void addConnectionEventListener(ConnectionEventListener connectionEventListener)
- Specified by:
addConnectionEventListener in interface ManagedConnection
removeConnectionEventListener
public void removeConnectionEventListener(ConnectionEventListener connectionEventListener)
- Specified by:
removeConnectionEventListener in interface ManagedConnection
getXAResource
public XAResource getXAResource()
throws ResourceException
- Specified by:
getXAResource in interface ManagedConnection
- Throws:
ResourceException
getLocalTransaction
public LocalTransaction getLocalTransaction()
throws ResourceException
- Specified by:
getLocalTransaction in interface ManagedConnection
- Throws:
ResourceException
getMetaData
public ManagedConnectionMetaData getMetaData()
throws ResourceException
- Specified by:
getMetaData in interface ManagedConnection
- Throws:
ResourceException
setLogWriter
public void setLogWriter(PrintWriter logWriter)
throws ResourceException
- Specified by:
setLogWriter in interface ManagedConnection
- Throws:
ResourceException
getLogWriter
public PrintWriter getLogWriter()
throws ResourceException
- Specified by:
getLogWriter in interface ManagedConnection
- Throws:
ResourceException
toString
public String toString()
- Overrides:
toString in class Object
This software is published under the BSD license. Copyright © 2003-2007, OMEX AG, Switzerland, All rights reserved. Use is subject to license terms.