public class ManagedTransactionAdapter extends java.lang.Object implements Transaction
TransactionManager reference and creating
a JTA Transaction handle for it.| Constructor and Description |
|---|
ManagedTransactionAdapter(TransactionManager transactionManager)
Create a new ManagedTransactionAdapter for the given TransactionManager.
|
| Modifier and Type | Method and Description |
|---|---|
void |
commit() |
boolean |
delistResource(XAResource xaRes,
int flag) |
boolean |
enlistResource(XAResource xaRes) |
int |
getStatus() |
TransactionManager |
getTransactionManager()
Return the JTA TransactionManager that this adapter delegates to.
|
void |
registerSynchronization(Synchronization sync) |
void |
rollback() |
void |
setRollbackOnly() |
public ManagedTransactionAdapter(TransactionManager transactionManager) throws SystemException
transactionManager - the JTA TransactionManager to wrapSystemExceptionpublic final TransactionManager getTransactionManager()
public void commit()
throws RollbackException,
HeuristicMixedException,
HeuristicRollbackException,
java.lang.SecurityException,
SystemException
commit in interface TransactionRollbackExceptionHeuristicMixedExceptionHeuristicRollbackExceptionjava.lang.SecurityExceptionSystemExceptionpublic void rollback()
throws SystemException
rollback in interface TransactionSystemExceptionpublic void setRollbackOnly()
throws SystemException
setRollbackOnly in interface TransactionSystemExceptionpublic int getStatus()
throws SystemException
getStatus in interface TransactionSystemExceptionpublic boolean enlistResource(XAResource xaRes) throws RollbackException, SystemException
enlistResource in interface TransactionRollbackExceptionSystemExceptionpublic boolean delistResource(XAResource xaRes, int flag) throws SystemException
delistResource in interface TransactionSystemExceptionpublic void registerSynchronization(Synchronization sync) throws RollbackException, SystemException
registerSynchronization in interface TransactionRollbackExceptionSystemException