Package net.sf.saxon.expr.sort
Class LocalOrderComparer
- java.lang.Object
-
- net.sf.saxon.expr.sort.LocalOrderComparer
-
- All Implemented Interfaces:
java.io.Serializable
,ItemOrderComparer
public final class LocalOrderComparer extends java.lang.Object implements ItemOrderComparer, java.io.Serializable
A Comparer used for comparing nodes in document order. This comparer assumes that the nodes being compared come from the same document- Author:
- Michael H. Kay
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description LocalOrderComparer()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description int
compare(Item a, Item b)
Compare two objects.static LocalOrderComparer
getInstance()
Get an instance of a LocalOrderComparer.
-
-
-
Method Detail
-
getInstance
public static LocalOrderComparer getInstance()
Get an instance of a LocalOrderComparer. The class maintains no state so this returns the same instance every time.
-
compare
public int compare(Item a, Item b)
Description copied from interface:ItemOrderComparer
Compare two objects.- Specified by:
compare
in interfaceItemOrderComparer
- Returns:
- <0 if a0 if a>b
-
-