public class UppercaseFirstCollator extends java.lang.Object implements StringCollator, java.io.Serializable
| Constructor and Description |
|---|
UppercaseFirstCollator(StringCollator base)
Create an UppercaseFirstCollator
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
comparesEqual(java.lang.String s1,
java.lang.String s2)
Compare two strings for equality.
|
int |
compareStrings(java.lang.String a,
java.lang.String b)
Compare two string objects: case is irrelevant, unless the strings are equal ignoring
case, in which case uppercase comes first.
|
java.lang.Object |
getCollationKey(java.lang.String s)
Get a collation key for two Strings.
|
public UppercaseFirstCollator(StringCollator base)
base - the base collator used to compare strings irrespective of casepublic int compareStrings(java.lang.String a,
java.lang.String b)
compareStrings in interface StringCollatora - the first stringb - the second stringjava.lang.ClassCastException - if the objects do not implement the CharSequence interfacepublic boolean comparesEqual(java.lang.String s1,
java.lang.String s2)
comparesEqual in interface StringCollators1 - the first strings2 - the second stringpublic java.lang.Object getCollationKey(java.lang.String s)
getCollationKey in interface StringCollators - the string whose collation key is required