|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectnet.sf.saxon.expr.sort.CaseFirstCollator
public class CaseFirstCollator
A StringCollator that sorts lowercase before uppercase, or vice versa.
Case is irrelevant, unless the strings are equal ignoring case, in which case lowercase comes first.
| Constructor Summary | |
|---|---|
CaseFirstCollator(StringCollator base,
boolean upperFirst)
Create a CaseFirstCollator |
|
| Method Summary | |
|---|---|
boolean |
comparesEqual(String s1,
String s2)
Compare two strings for equality. |
int |
compareStrings(String a,
String b)
Compare two string objects: case is irrelevant, unless the strings are equal ignoring case, in which case lowercase comes first. |
Object |
getCollationKey(String s)
Get a collation key for two Strings. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public CaseFirstCollator(StringCollator base,
boolean upperFirst)
base - the base collator, which determines how characters are sorted irrespective of caseupperFirst - true if uppercase precedes lowercase, false otherwise| Method Detail |
|---|
public int compareStrings(String a,
String b)
compareStrings in interface StringCollatora - the first stringb - the second string
ClassCastException - if the objects are of the wrong type for this Comparer
public boolean comparesEqual(String s1,
String s2)
comparesEqual in interface StringCollators1 - the first strings2 - the second string
public Object getCollationKey(String s)
getCollationKey in interface StringCollators - the string whose collation key is required
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||