Class TSXaTransaction
java.lang.Object
com.sun.ts.tests.common.connector.whitebox.TSXaTransaction
Class representing one Global Transaction.
- Version:
- 1.0, 06/06/02
- Author:
- Binod P.G
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionvoidAdds the connection to this transaction.voidcommit(boolean onePhase) Commits this Transaction.intGet the status of the transaction.intprepare()Prepare the transaction.Check for the key in the transaction.voidrollback()Rolls back the transactionvoidsetStatus(int status) Sets the Status of the transaction.
- 
Constructor Details- 
TSXaTransactionCreates a new Global Transaction object.- Parameters:
- id- Global Transaction Identifier.
 
 
- 
- 
Method Details- 
addConnectionAdds the connection to this transaction.- Parameters:
- con- Connection involved in the transaction branch.
 
- 
setStatuspublic void setStatus(int status) Sets the Status of the transaction.- Parameters:
- Status- of the transaction
 
- 
getStatuspublic int getStatus()Get the status of the transaction.- Returns:
- Status of the transaction.
 
- 
preparePrepare the transaction.- Returns:
- The Vote of this branch in this transaction.
- Throws:
- XAException- If prepare fails.
 
- 
commitCommits this Transaction.- Parameters:
- Boolean- indicating, whether it is a single-phase or 2-phase commit.
- Throws:
- XAException- If commit fails.
 
- 
rollbackpublic void rollback()Rolls back the transaction
- 
readCheck for the key in the transaction. If it is not readable return null.- Parameters:
- elementkey- Key to be read.
- Returns:
- DataElement object.
- Throws:
- TSEISException- In case, read fails.
 
 
-