public class UserTransactionProxy extends java.lang.Object implements UserTransaction, TransactionManager, java.io.Serializable
Modifier and Type | Method and Description |
---|---|
void |
abortTransaction()
Finish any transaction.
|
void |
begin()
Start the transaction.
|
void |
commit()
Commits the transaction
|
static UserTransactionProxy |
getCurrent()
Returns the local UT proxy.
|
UserTransactionImpl |
getCurrentUserTransactionImpl()
Gets the current thread transaction.
|
static UserTransactionProxy |
getInstance()
Returns the local UT proxy.
|
int |
getStatus()
Gets the transaction's status
|
Transaction |
getTransaction()
Returns the current transaction.
|
UserTransactionImpl |
getUserTransaction()
Gets the thread transaction.
|
void |
recover(XAResource xaRes)
Recovers an XAResource
|
void |
resume(Transaction transaction)
Resume a transaction.
|
void |
rollback()
Rolls the transaction back
|
void |
setRollbackOnly()
Marks the transaction as rollback only.
|
void |
setRollbackOnly(java.lang.Exception e)
Marks the transaction as rollback only.
|
void |
setTransactionTimeout(int seconds)
Sets the transaction's timeout.
|
Transaction |
suspend()
Suspends the transaction.
|
java.lang.String |
toString() |
public static UserTransactionProxy getInstance()
public static UserTransactionProxy getCurrent()
public UserTransactionImpl getUserTransaction()
public UserTransactionImpl getCurrentUserTransactionImpl()
public void setTransactionTimeout(int seconds) throws SystemException
setTransactionTimeout
in interface TransactionManager
setTransactionTimeout
in interface UserTransaction
SystemException
public int getStatus() throws SystemException
getStatus
in interface TransactionManager
getStatus
in interface UserTransaction
SystemException
public void begin() throws NotSupportedException, SystemException
begin
in interface TransactionManager
begin
in interface UserTransaction
NotSupportedException
SystemException
public void setRollbackOnly() throws java.lang.IllegalStateException, SystemException
setRollbackOnly
in interface TransactionManager
setRollbackOnly
in interface UserTransaction
java.lang.IllegalStateException
SystemException
public void setRollbackOnly(java.lang.Exception e) throws java.lang.IllegalStateException
java.lang.IllegalStateException
public void commit() throws java.lang.IllegalStateException, RollbackException, HeuristicMixedException, HeuristicRollbackException, java.lang.SecurityException, SystemException
commit
in interface TransactionManager
commit
in interface UserTransaction
java.lang.IllegalStateException
RollbackException
HeuristicMixedException
HeuristicRollbackException
java.lang.SecurityException
SystemException
public void rollback() throws java.lang.IllegalStateException, java.lang.SecurityException, SystemException
rollback
in interface TransactionManager
rollback
in interface UserTransaction
java.lang.IllegalStateException
java.lang.SecurityException
SystemException
public void abortTransaction() throws java.lang.IllegalStateException
java.lang.IllegalStateException
public void recover(XAResource xaRes) throws XAException
XAException
public Transaction getTransaction() throws SystemException
getTransaction
in interface TransactionManager
SystemException
public Transaction suspend() throws SystemException
suspend
in interface TransactionManager
SystemException
public void resume(Transaction transaction) throws java.lang.IllegalStateException, InvalidTransactionException, SystemException
resume
in interface TransactionManager
java.lang.IllegalStateException
InvalidTransactionException
SystemException
public java.lang.String toString()
toString
in class java.lang.Object