tppt.xopen
Interface TX
- All Known Subinterfaces:
- TMInterface
- public interface TX
TX
is the name of the service shared by the AP and the TM.
The TX functions are provided by TM and are called by APs.
This interface is revised from the X/Open standard.
- Version:
- 2.0
- Author:
- Jodie Wu
Method Summary |
int |
tx_begin()
AP calls this method to obtains the global transaction id. |
boolean |
tx_close(int tid)
AP called this method to close this global transaction. |
boolean |
tx_commit(int tid)
AP called this method to tell TM that it is ready to commit and then
TM will start to perform two-phase commit protocol. |
tx_begin
public int tx_begin()
- AP calls this method to obtains the global transaction id.
- Returns:
- transaction id.
tx_close
public boolean tx_close(int tid)
- AP called this method to close this global transaction.
- Parameters:
tid
- the transaction id- Returns:
- true if close properly; false otherwise/
tx_commit
public boolean tx_commit(int tid)
- AP called this method to tell TM that it is ready to commit and then
TM will start to perform two-phase commit protocol.
- Parameters:
ap
- The instance of the ApplicationProgram.- Returns:
- true if two-phase commit protocol execute properly; false otherwise.