public class ManagedConnectionImpl extends Object implements javax.resource.spi.ManagedConnection
| Constructor and Description |
|---|
ManagedConnectionImpl(ManagedConnectionFactoryImpl mcf,
javax.resource.spi.security.PasswordCredential credential)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addConnectionEventListener(javax.resource.spi.ConnectionEventListener cel)
Mutator to add a connection listener
|
void |
associateConnection(Object c)
Mutator to associate a connection
|
void |
begin()
Method to start the Transaction
|
void |
cleanup()
Cleanup method
|
void |
destroy()
Destroy method
|
Object |
getConnection(Subject subject,
javax.resource.spi.ConnectionRequestInfo cri)
Accessor for the connection
|
javax.resource.spi.LocalTransaction |
getLocalTransaction()
Accessor for the local transaction
|
PrintWriter |
getLogWriter()
Accessor for the Log
|
javax.resource.spi.ManagedConnectionMetaData |
getMetaData()
Accessor for the connection MetaData
|
org.datanucleus.api.jdo.JDOPersistenceManager |
getPersistenceManager() |
XAResource |
getXAResource()
Accessor for the XA resource.
|
void |
removeConnectionEventListener(javax.resource.spi.ConnectionEventListener cel)
Mutator to remove a connection listener
|
void |
setLogWriter(PrintWriter writer)
Mutator for the Log
|
public ManagedConnectionImpl(ManagedConnectionFactoryImpl mcf, javax.resource.spi.security.PasswordCredential credential) throws javax.resource.ResourceException
mcf - the ManagedConnectionFactorycredential - the PasswordCredentialjavax.resource.ResourceException - if error occurspublic void begin()
public void destroy()
throws javax.resource.ResourceException
destroy in interface javax.resource.spi.ManagedConnectionjavax.resource.ResourceException - if error occurspublic void cleanup()
throws javax.resource.ResourceException
cleanup in interface javax.resource.spi.ManagedConnectionjavax.resource.ResourceException - if error occurspublic org.datanucleus.api.jdo.JDOPersistenceManager getPersistenceManager()
public Object getConnection(Subject subject, javax.resource.spi.ConnectionRequestInfo cri) throws javax.resource.ResourceException
getConnection in interface javax.resource.spi.ManagedConnectionsubject - The subjectcri - request infojavax.resource.ResourceException - if error occurspublic PrintWriter getLogWriter() throws javax.resource.ResourceException
getLogWriter in interface javax.resource.spi.ManagedConnectionjavax.resource.ResourceException - if error occurspublic void setLogWriter(PrintWriter writer) throws javax.resource.ResourceException
setLogWriter in interface javax.resource.spi.ManagedConnectionwriter - PrintWriter to use for Logjavax.resource.ResourceException - if error occurspublic void addConnectionEventListener(javax.resource.spi.ConnectionEventListener cel)
addConnectionEventListener in interface javax.resource.spi.ManagedConnectioncel - event listenerpublic void removeConnectionEventListener(javax.resource.spi.ConnectionEventListener cel)
removeConnectionEventListener in interface javax.resource.spi.ManagedConnectioncel - event listenerpublic void associateConnection(Object c) throws javax.resource.ResourceException
associateConnection in interface javax.resource.spi.ManagedConnectionc - connectionjavax.resource.ResourceException - if error occurspublic javax.resource.spi.LocalTransaction getLocalTransaction()
throws javax.resource.ResourceException
getLocalTransaction in interface javax.resource.spi.ManagedConnectionjavax.resource.ResourceException - if error occurspublic javax.resource.spi.ManagedConnectionMetaData getMetaData()
throws javax.resource.ResourceException
getMetaData in interface javax.resource.spi.ManagedConnectionjavax.resource.ResourceException - if error occurspublic XAResource getXAResource() throws javax.resource.ResourceException
getXAResource in interface javax.resource.spi.ManagedConnectionjavax.resource.ResourceException - if error occursCopyright © 2018. All rights reserved.