Class GlobalTID


  • public class GlobalTID
    extends Object
    This class provides a wrapper for the otid_t class in the org.omg.CosTSInteroperation package to allow us to add operations.
    Version:
    0.01
    Author:
    Simon Holdsworth, IBM Corporation
    • Constructor Detail

      • GlobalTID

        public GlobalTID​(org.omg.CosTransactions.otid_t otherTID)
        Creates a new global identifier which is a copy of the parameter.
        Parameters:
        otherTID - The other global identifier.
      • GlobalTID

        public GlobalTID​(Xid xid)
        Creates a new global identifier object.
        Parameters:
        xid - The Xid object containing transaction id.
      • GlobalTID

        public GlobalTID​(String stid)
    • Method Detail

      • equals

        public final boolean equals​(Object other)
        Compares the two global identifiers. Delegates to #isSameTIDInternal for the actual implementation to avoid comparison with otid_t that FindBugs doesn't like.
        Overrides:
        equals in class Object
        Parameters:
        other - The other global identifier to compare.
        Returns:
        Indicates the two global identifiers are equal.
      • isSameTID

        public final boolean isSameTID​(org.omg.CosTransactions.otid_t otherTID)
      • hashCode

        public final int hashCode()
        Returns a hash value for the global identifier.
        Overrides:
        hashCode in class Object
        Returns:
        The hash value.
      • toString

        public final String toString()
        Converts the global identifier to a string.
        Overrides:
        toString in class Object
        Returns:
        The string representation of the identifier.