org.exolab.core.foundation
Class TransactionStatus

java.lang.Object
  extended by org.exolab.core.foundation.TransactionStatus

public final class TransactionStatus
extends java.lang.Object

This class defines the various states of a transaction.A transaction can be in one three possible states.

OPENED a begin has been issues and the transaction is in progress COMMITTED the transaction has been successfully commited ROLLOEDBACK the transaction has been successfully rolled back

A lot of these concepts have been borrowed from Castor

Version:
$Revision: 1.1 $ $Date: 2000/03/09 23:52:43 $
Author:
Jim Alateras

Field Summary
static TransactionStatus ABORTED
           
static TransactionStatus CLOSED
           
static TransactionStatus COMMITTED
           
static TransactionStatus OPENED
          Instatiate instances related to each of the enumerations
 
Method Summary
 boolean equals(java.lang.Object obj)
          Return true iff the two specified object are of the same type and their ordinal values are identical.
 int getOrd()
          Returns the ordinal value for this state
 boolean isOpened()
          Check if the transaction status is set to OPENED
static int size()
          Returns the number of states in this enumeration
 java.lang.String toString()
          Returns the name of this state
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

OPENED

public static final TransactionStatus OPENED
Instatiate instances related to each of the enumerations


CLOSED

public static final TransactionStatus CLOSED

COMMITTED

public static final TransactionStatus COMMITTED

ABORTED

public static final TransactionStatus ABORTED
Method Detail

getOrd

public int getOrd()
Returns the ordinal value for this state

Returns:
int

toString

public java.lang.String toString()
Returns the name of this state

Overrides:
toString in class java.lang.Object
Returns:
String

size

public static int size()
Returns the number of states in this enumeration

Returns:
int

equals

public boolean equals(java.lang.Object obj)
Return true iff the two specified object are of the same type and their ordinal values are identical.

Overrides:
equals in class java.lang.Object
Parameters:
obj - object to compare against
Returns:
boolean true if objects are equivalent

isOpened

public boolean isOpened()
Check if the transaction status is set to OPENED

Returns:
boolean true if opened, false is otherwise


Copyright © 1999-2012 The Exolab Group. All Rights Reserved.