com.metamatrix.common.id
Class TransactionID

java.lang.Object
  extended by com.metamatrix.core.id.LongID
      extended by com.metamatrix.common.id.TransactionID
All Implemented Interfaces:
ObjectID, java.io.Serializable, java.lang.Comparable

public class TransactionID
extends LongID

See Also:
Serialized Form

Field Summary
protected static java.lang.String PROTOCOL
           
 
Fields inherited from interface com.metamatrix.core.id.ObjectID
DELIMITER
 
Method Summary
 int compareTo(java.lang.Object obj)
          Compares this object to another.
 boolean equals(java.lang.Object obj)
          Returns true if the specified object is semantically equal to this instance.
 java.lang.String getProtocol()
          Return the name of the protocol that this factory uses.
 java.lang.String toString()
          Returns a string representing the current state of the object.
 
Methods inherited from class com.metamatrix.core.id.LongID
getValue, hashCode, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

PROTOCOL

protected static final java.lang.String PROTOCOL
See Also:
Constant Field Values
Method Detail

equals

public boolean equals(java.lang.Object obj)
Returns true if the specified object is semantically equal to this instance. Note: this method is consistent with compareTo().

Overrides:
equals in class LongID
Parameters:
obj - the object that this instance is to be compared to.
Returns:
whether the object is equal to this object.

compareTo

public int compareTo(java.lang.Object obj)
Compares this object to another. If the specified object is not an instance of the LongID class, then this method throws a ClassCastException (as instances are comparable only to instances of the same class). Note: this method is consistent with equals(), meaning that (compare(x, y)==0) == (x.equals(y)).

Specified by:
compareTo in interface ObjectID
Specified by:
compareTo in interface java.lang.Comparable
Overrides:
compareTo in class LongID
Parameters:
obj - the object that this instance is to be compared to; may not be null.
Returns:
a negative integer, zero, or a positive integer as this object is less than, equal to, or greater than the specified object, respectively.
Throws:
java.lang.ClassCastException - if the specified object's type prevents it from being compared to this instance.

toString

public java.lang.String toString()
Returns a string representing the current state of the object.

Specified by:
toString in interface ObjectID
Overrides:
toString in class LongID
Returns:
the string representation of this instance.

getProtocol

public java.lang.String getProtocol()
Return the name of the protocol that this factory uses.

Specified by:
getProtocol in interface ObjectID
Overrides:
getProtocol in class LongID
Returns:
the protocol name


Copyright © 2009. All Rights Reserved.