org.axonframework.unitofwork
Class NoTransactionManager

java.lang.Object
  extended by org.axonframework.unitofwork.NoTransactionManager
All Implemented Interfaces:
TransactionManager

public class NoTransactionManager
extends Object
implements TransactionManager

TransactionManager implementation that does nothing. Is a placeholder implementation for the cases where no special transaction management is required.

Since:
2.0
Author:
Allard Buijze

Constructor Summary
NoTransactionManager()
           
 
Method Summary
 void commitTransaction(Object transactionStatus)
          Commits the transaction identifier by given transactionStatus.
 void rollbackTransaction(Object transaction)
          Rolls back the transaction identifier by given transactionStatus.
 Object startTransaction()
          Starts a transaction.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

NoTransactionManager

public NoTransactionManager()
Method Detail

startTransaction

public Object startTransaction()
Description copied from interface: TransactionManager
Starts a transaction. The return value is an object representing the transaction status and must be passed as an argument when invoking TransactionManager.commitTransaction(Object) or TransactionManager.rollbackTransaction(Object).

The returned object must never be null if a transaction was successfully created.

Specified by:
startTransaction in interface TransactionManager
Returns:
The object representing the transaction status

commitTransaction

public void commitTransaction(Object transactionStatus)
Description copied from interface: TransactionManager
Commits the transaction identifier by given transactionStatus.

Specified by:
commitTransaction in interface TransactionManager
Parameters:
transactionStatus - The status object provided by TransactionManager.startTransaction().

rollbackTransaction

public void rollbackTransaction(Object transaction)
Description copied from interface: TransactionManager
Rolls back the transaction identifier by given transactionStatus.

Specified by:
rollbackTransaction in interface TransactionManager
Parameters:
transaction - The status object provided by TransactionManager.startTransaction().


Copyright © 2010-2016. All Rights Reserved.