public static class KElement.SingleXPathComparator extends java.lang.Object implements java.util.Comparator<KElement>
| Constructor and Description |
|---|
SingleXPathComparator(java.lang.String xPath,
boolean pInvert)
if the attribute is numeric, compare numerically, else lexical comparison is done
|
SingleXPathComparator(java.lang.String xPath,
boolean pInvert,
boolean checkNumber,
boolean caseSensitive) |
| Modifier and Type | Method and Description |
|---|---|
int |
compare(KElement o1,
KElement o2) |
boolean |
isCaseSensitive() |
boolean |
isCheckNumber() |
void |
setCaseSensitive(boolean caseSensitive) |
void |
setCheckNumber(boolean checkNumber) |
public SingleXPathComparator(java.lang.String xPath,
boolean pInvert)
xPath - the xpath in the context of this element to use for comparingpInvert - if true, sort backwardspublic SingleXPathComparator(java.lang.String xPath,
boolean pInvert,
boolean checkNumber,
boolean caseSensitive)
public int compare(KElement o1, KElement o2)
compare in interface java.util.Comparator<KElement>o1 - o2 - Comparator.compare(java.lang.Object, java.lang.Object)public boolean isCheckNumber()
public void setCheckNumber(boolean checkNumber)
public boolean isCaseSensitive()
public void setCaseSensitive(boolean caseSensitive)