-
-class TransactionStatus {
- static final char StatusAborted = 1;
- static final char StatusPending = 2;
- static final char StatusCommitted = 3;
- // static final char StatusRetrying = 4;
- static final char StatusSentPartial = 5;
- static final char StatusSentFully = 6;
- static final char StatusNoEffect = 10;
-
- char status = 0;
- bool applicationReleased = false;
- bool wasSentInChain = false;
- int64_t transactionSequenceNumber = 0;
- int64_t arbitrator = -1;
-
-
- TransactionStatus(char _status, int64_t _arbitrator) {
- status = _status;
- arbitrator = _arbitrator;
- }
-
- char getStatus() {
- return status;
- }
-
- void setStatus(char _status) {
- status = _status;
- }
-
- int64_t getTransactionSequenceNumber() {
- return transactionSequenceNumber;
- }
-
- void setTransactionSequenceNumber(int64_t _transactionSequenceNumber) {
- transactionSequenceNumber = _transactionSequenceNumber;
- }
-
- int64_t getTransactionArbitrator() {
- return arbitrator;
- }
-
- void release() {
- applicationReleased = true;
- }
-
- bool getReleased() {
- return applicationReleased;
- }
-}