Class Int32MapKey

java.lang.Object
net.sf.saxon.ma.map.Int32MapKey
All Implemented Interfaces:
AtomicMatchKey

public class Int32MapKey extends Object implements AtomicMatchKey
An Int32MapKey is the AtomicMatchKey used for all numeric values that are numerically equal to some 32-bit signed integer, regardless of the primitive type of the actual numeric value.
  • Constructor Details

    • Int32MapKey

      public Int32MapKey(int key)
  • Method Details

    • asAtomic

      public AtomicValue asAtomic()
      Get an atomic value that encapsulates this match key. Needed to support the collation-key() function.
      Specified by:
      asAtomic in interface AtomicMatchKey
      Returns:
      an atomic value that encapsulates this match key. NB: this is NOT (necessarily) the atomic value from which the AtomicMatchKey was derived.
    • equals

      public boolean equals(Object obj)
      Indicates whether some other object is "equal to" this one. The algorithm for allocating map keys is designed to ensure that a numeric value that is numerically equal to some 32-bit integer is always represented by an instance of Int32MapKey, and therefore the keys can be directly compared using an integer comparison.
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Returns a hash code value for the object.
      Overrides:
      hashCode in class Object