GetStatus
Description
Returns the status of the EJB transaction associated with the
client.
Syntax
|
1 |
ejbtrans.GetStatus ( ) |
|
Argument |
Description |
|---|---|
|
ejbtrans |
The name of an EJBTransaction object |
Return value
A long value representing the transaction status
Possible values are:
1 — Status active
2 — Status marked rollback
3 — Status prepared
4 — Status committed
5 — Status rolled back
6 — Status unknown
7 — Status no transaction
8 — Status preparing
9 — Status committing
10 — Status rolling back
Examples
This example shows the use of GetStatus to obtain the state of the
current transaction:
|
1 2 3 4 5 6 7 |
// Instance variables: // EJBConnection myconnect EJBTransaction mytrans long ll_status mytrans = myconnect.GetEJBTransaction() ll_status = mytrans.GetStatus() |
Usage
The GetStatus method can be used to determine the current status
of a transaction by the client that initiated the transaction using the
Begin method.
See also
GetEJBTransaction
(EJBConnection class)