Class StandaloneTransactionContext
- java.lang.Object
-
- org.camunda.bpm.engine.impl.cfg.standalone.StandaloneTransactionContext
-
- All Implemented Interfaces:
TransactionContext
public class StandaloneTransactionContext extends Object implements TransactionContext
- Author:
- Sebastian Menski
-
-
Field Summary
Fields Modifier and Type Field Description protected CommandContext
commandContext
protected Map<TransactionState,List<TransactionListener>>
stateTransactionListeners
-
Constructor Summary
Constructors Constructor Description StandaloneTransactionContext(CommandContext commandContext)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addTransactionListener(TransactionState transactionState, TransactionListener transactionListener)
Add aTransactionListener
to the current transaction.void
commit()
Commit the current transaction.protected void
fireTransactionEvent(TransactionState transactionState)
boolean
isTransactionActive()
void
rollback()
Rollback the current transaction.protected void
setLastTransactionState(TransactionState transactionState)
-
-
-
Field Detail
-
commandContext
protected CommandContext commandContext
-
stateTransactionListeners
protected Map<TransactionState,List<TransactionListener>> stateTransactionListeners
-
-
Constructor Detail
-
StandaloneTransactionContext
public StandaloneTransactionContext(CommandContext commandContext)
-
-
Method Detail
-
addTransactionListener
public void addTransactionListener(TransactionState transactionState, TransactionListener transactionListener)
Description copied from interface:TransactionContext
Add aTransactionListener
to the current transaction.- Specified by:
addTransactionListener
in interfaceTransactionContext
- Parameters:
transactionState
- the transaction state for which theTransactionListener
should be added.transactionListener
- theTransactionListener
to add.
-
commit
public void commit()
Description copied from interface:TransactionContext
Commit the current transaction.- Specified by:
commit
in interfaceTransactionContext
-
fireTransactionEvent
protected void fireTransactionEvent(TransactionState transactionState)
-
setLastTransactionState
protected void setLastTransactionState(TransactionState transactionState)
-
rollback
public void rollback()
Description copied from interface:TransactionContext
Rollback the current transaction.- Specified by:
rollback
in interfaceTransactionContext
-
isTransactionActive
public boolean isTransactionActive()
- Specified by:
isTransactionActive
in interfaceTransactionContext
-
-