Class TransactionHandlerImpl
java.lang.Object
com.sun.xml.ws.rx.rm.runtime.transaction.TransactionHandlerImpl
- All Implemented Interfaces:
TransactionHandler
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidbegin(int txTimeout) Begin the transactionbooleancanBegin()Can UserTransaction be started? Can start only if it doesn't already exist.voidcommit()Commit the transactionintjakarta.transaction.Status of the UserTransactionjakarta.transaction.Status as a String.booleanisActive()Is the UserTransaction active on this thread?booleanIs the UserTransaction marked for roll back?voidrollback()Roll back the transactionvoidMark the transaction as roll back onlybooleanIs transaction associated with the current thread?booleanIs the UserTransaction available?
-
Constructor Details
-
TransactionHandlerImpl
public TransactionHandlerImpl()Default constructor.
-
-
Method Details
-
begin
Description copied from interface:TransactionHandlerBegin the transaction- Specified by:
beginin interfaceTransactionHandler- Parameters:
txTimeout- Transaction timeout in seconds- Throws:
TransactionException
-
commit
Description copied from interface:TransactionHandlerCommit the transaction- Specified by:
commitin interfaceTransactionHandler- Throws:
TransactionException
-
rollback
Description copied from interface:TransactionHandlerRoll back the transaction- Specified by:
rollbackin interfaceTransactionHandler- Throws:
TransactionException
-
setRollbackOnly
Description copied from interface:TransactionHandlerMark the transaction as roll back only- Specified by:
setRollbackOnlyin interfaceTransactionHandler- Throws:
TransactionException
-
userTransactionAvailable
Description copied from interface:TransactionHandlerIs the UserTransaction available?- Specified by:
userTransactionAvailablein interfaceTransactionHandler- Returns:
- true if UserTransaction can be looked up from JNDI, otherwise false
- Throws:
TransactionException
-
isActive
Description copied from interface:TransactionHandlerIs the UserTransaction active on this thread?- Specified by:
isActivein interfaceTransactionHandler- Returns:
- true if UserTransaction status is active
- Throws:
TransactionException
-
isMarkedForRollback
Description copied from interface:TransactionHandlerIs the UserTransaction marked for roll back?- Specified by:
isMarkedForRollbackin interfaceTransactionHandler- Returns:
- true if UserTransaction is marked for roll back
- Throws:
TransactionException
-
canBegin
public boolean canBegin()Description copied from interface:TransactionHandlerCan UserTransaction be started? Can start only if it doesn't already exist.- Specified by:
canBeginin interfaceTransactionHandler- Returns:
- true if UserTransaction can be started
-
transactionExists
Description copied from interface:TransactionHandlerIs transaction associated with the current thread?- Specified by:
transactionExistsin interfaceTransactionHandler- Returns:
- true if transaction is flowing on the current thread
- Throws:
TransactionException
-
getStatus
Description copied from interface:TransactionHandlerjakarta.transaction.Status of the UserTransaction- Specified by:
getStatusin interfaceTransactionHandler- Returns:
- status integer of the UserTransaction
- Throws:
TransactionException
-
getStatusAsString
Description copied from interface:TransactionHandlerjakarta.transaction.Status as a String. Useful for logging.- Specified by:
getStatusAsStringin interfaceTransactionHandler- Returns:
- status as a String
- Throws:
TransactionException
-