|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.jboss.soa.esb.common.TransactionStrategy
public abstract class TransactionStrategy
This class represents the transaction strategy that is currently in force within the ESB. At present there are two strategies employed, a null strategy when running outside of an application server environment and a JTA strategy when running within.
Constructor Summary | |
---|---|
TransactionStrategy()
|
Method Summary | |
---|---|
abstract void |
begin()
Begin a transaction on the current thread. |
abstract void |
enlistResource(javax.transaction.xa.XAResource resource)
Add a resource to the current transaction. |
abstract java.lang.Object |
getTransaction()
Get a handle on the currently associated transaction (or null). |
static TransactionStrategy |
getTransactionStrategy(boolean transacted)
Get the active transaction strategy. |
abstract boolean |
isActive()
Is the currently associated transaction active? |
abstract void |
registerSynchronization(javax.transaction.Synchronization sync)
Add a synchronization to the current transaction. |
abstract void |
resume(java.lang.Object tx)
Associated the transaction with the current thread. |
abstract void |
rollbackOnly()
Mark the current transaction for rollback. |
static void |
setTransactionStrategy(TransactionStrategy transactionStrategy)
Set the active transaction strategy. |
abstract java.lang.Object |
suspend()
Suspend the current thread-to-transaction association. |
abstract void |
terminate()
Terminate the transaction on the current thread. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public TransactionStrategy()
Method Detail |
---|
public static TransactionStrategy getTransactionStrategy(boolean transacted)
transacted
- True if the current transacted strategy is required, false for a null strategy.
public static void setTransactionStrategy(TransactionStrategy transactionStrategy)
transactionStrategy
- The transaction strategy.public abstract void begin() throws TransactionStrategyException
TransactionStrategyException
public abstract void terminate() throws TransactionStrategyException
TransactionStrategyException
public abstract void rollbackOnly() throws TransactionStrategyException
TransactionStrategyException
public abstract java.lang.Object getTransaction() throws TransactionStrategyException
TransactionStrategyException
public abstract java.lang.Object suspend() throws TransactionStrategyException
TransactionStrategyException
public abstract boolean isActive() throws TransactionStrategyException
TransactionStrategyException
public abstract void resume(java.lang.Object tx) throws TransactionStrategyException
tx
-
TransactionStrategyException
public abstract void registerSynchronization(javax.transaction.Synchronization sync) throws TransactionStrategyException
sync
-
TransactionStrategyException
public abstract void enlistResource(javax.transaction.xa.XAResource resource) throws TransactionStrategyException
resource
-
TransactionStrategyException
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |