com.sssw.fw.util
Class EboComparator
java.lang.Object
|
+--com.sssw.fw.util.EboComparator
- All Implemented Interfaces:
- EbiComparator
- public class EboComparator
- extends Object
- implements EbiComparator
This class is the default implementation of the
com.sssw.fw.api.EbiComparator interface. See also
com.sssw.fw.util.EboQSort.
Method Summary |
int |
compare(Object o1,
Object o2)
Determine the comparative ranking of two objects. |
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
EboComparator
public EboComparator()
compare
public int compare(Object o1,
Object o2)
- Determine the comparative ranking of two objects. Answer:
- IN_ORDER if o1 followed by o2 is the desired order
- EQUIVALENT if o1 and o2 have equivalent ranking values
- REVERSE_ORDER if o1 followed by o2 is the reverse of the desired order
Note:This method assumes that the supplied
objects are Strings.
- Specified by:
- compare in interface EbiComparator
- Parameters:
o1
- the first object to compareo2
- the second object to compare- Returns:
- the resulting ranking of the two objects