public class RegistryManagedRuntime.TransactionManagerRegistryFacade extends Object implements TransactionManager, Transaction
TransactionManager
and Transaction
facade
that delegates the appropriate methods to the internally-held
TransactionSynchronizationRegistry
. Since the
registry is not able to start or end transactions, all transaction
control methods will just throw a SystemException
.Constructor and Description |
---|
TransactionManagerRegistryFacade(TransactionSynchronizationRegistry registry) |
Modifier and Type | Method and Description |
---|---|
void |
begin() |
void |
commit() |
boolean |
delistResource(XAResource xaRes,
int flag) |
boolean |
enlistResource(XAResource xaRes) |
int |
getStatus() |
Transaction |
getTransaction() |
Object |
getTransactionKey() |
void |
registerSynchronization(Synchronization sync) |
void |
resume(Transaction tobj) |
void |
rollback() |
void |
setRollbackOnly() |
void |
setTransactionTimeout(int seconds) |
Transaction |
suspend() |
public TransactionManagerRegistryFacade(TransactionSynchronizationRegistry registry)
public Transaction getTransaction() throws SystemException
getTransaction
in interface TransactionManager
SystemException
public void registerSynchronization(Synchronization sync) throws RollbackException, IllegalStateException, SystemException
registerSynchronization
in interface Transaction
RollbackException
IllegalStateException
SystemException
public void setRollbackOnly() throws IllegalStateException, SystemException
setRollbackOnly
in interface Transaction
setRollbackOnly
in interface TransactionManager
IllegalStateException
SystemException
public int getStatus() throws SystemException
getStatus
in interface Transaction
getStatus
in interface TransactionManager
SystemException
public Object getTransactionKey()
public void begin() throws NotSupportedException, SystemException
begin
in interface TransactionManager
NotSupportedException
SystemException
public void commit() throws RollbackException, HeuristicMixedException, SystemException, HeuristicRollbackException, SecurityException, IllegalStateException
commit
in interface Transaction
commit
in interface TransactionManager
RollbackException
HeuristicMixedException
SystemException
HeuristicRollbackException
SecurityException
IllegalStateException
public void resume(Transaction tobj) throws InvalidTransactionException, IllegalStateException, SystemException
resume
in interface TransactionManager
InvalidTransactionException
IllegalStateException
SystemException
public void rollback() throws IllegalStateException, SecurityException, SystemException
rollback
in interface Transaction
rollback
in interface TransactionManager
IllegalStateException
SecurityException
SystemException
public void setTransactionTimeout(int seconds) throws SystemException
setTransactionTimeout
in interface TransactionManager
SystemException
public Transaction suspend() throws SystemException
suspend
in interface TransactionManager
SystemException
public boolean delistResource(XAResource xaRes, int flag) throws IllegalStateException, SystemException
delistResource
in interface Transaction
IllegalStateException
SystemException
public boolean enlistResource(XAResource xaRes) throws RollbackException, IllegalStateException, SystemException
enlistResource
in interface Transaction
RollbackException
IllegalStateException
SystemException
Copyright © 2006–2019 Apache Software Foundation. All rights reserved.