Class StringIgnoreCaseKeyComparator

  • All Implemented Interfaces:
    java.io.Serializable, KeyComparator<java.lang.String>

    public class StringIgnoreCaseKeyComparator
    extends java.lang.Object
    implements KeyComparator<java.lang.String>
    Case insensitive String key comparator.
    See Also:
    Serialized Form
    • Constructor Detail

      • StringIgnoreCaseKeyComparator

        public StringIgnoreCaseKeyComparator()
    • Method Detail

      • hash

        public int hash​(java.lang.String k)
        Description copied from interface: KeyComparator
        Get the hash code of a key.
        Specified by:
        hash in interface KeyComparator<java.lang.String>
        Parameters:
        k - the key.
        Returns:
        the hash code of the key.
      • equals

        public boolean equals​(java.lang.String x,
                              java.lang.String y)
        Description copied from interface: KeyComparator
        Compare two keys for equality.
        Specified by:
        equals in interface KeyComparator<java.lang.String>
        Parameters:
        x - the first key
        y - the second key
        Returns:
        true if the keys are equal.