public class StringIgnoreCaseKeyComparator extends Object implements KeyComparator<String>
Modifier and Type | Field and Description |
---|---|
static StringIgnoreCaseKeyComparator |
SINGLETON |
Constructor and Description |
---|
StringIgnoreCaseKeyComparator() |
Modifier and Type | Method and Description |
---|---|
int |
compare(String o1,
String o2) |
boolean |
equals(String x,
String y)
Compare two keys for equality.
|
int |
hash(String k)
Get the hash code of a key.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
comparing, comparing, comparingDouble, comparingInt, comparingLong, equals, naturalOrder, nullsFirst, nullsLast, reversed, reverseOrder, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLong
public static final StringIgnoreCaseKeyComparator SINGLETON
public int hash(String k)
KeyComparator
hash
in interface KeyComparator<String>
k
- the key.public boolean equals(String x, String y)
KeyComparator
equals
in interface KeyComparator<String>
x
- the first keyy
- the second keypublic int compare(String o1, String o2)
compare
in interface Comparator<String>
Copyright © 2018 Oracle Corporation. All rights reserved.