com.sap.portal.obn.service.sort
Class ComplexComparator
java.lang.Object
com.sap.portal.obn.service.sort.ComplexComparator
- All Implemented Interfaces:
- Comparator
public class ComplexComparator
- extends Object
- implements Comparator
The class that defines complex sorting, based on multiple criteria.
Each criterion is determined by its comparator and sorting order (ascending or descending).
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ComplexComparator
public ComplexComparator()
removeAllCriterias
public void removeAllCriterias()
- Removes all criteria from the complex comparator
addCriteria
public void addCriteria(Comparator sortCriteria,
boolean isAscending)
- Adds a single criterion to the complex comparator
- Parameters:
sortCriteria - comparator of the new criterionisAscending - sorting order of the new criterion; if true, the original order provided by the criterion's comparator
is be used, otherwise the order is reversed
compare
public int compare(Object o1,
Object o2)
- Specified by:
compare in interface Comparator
- See Also:
Comparator.compare(java.lang.Object, java.lang.Object)
This class can be accessed from:
|
SC
|
DC
|
Public Part
|
ACH
|
[sap.com] EP-RUNTIME
|
[sap.com] tc/ep/navigation/api
|
api
|
EP-PIN
|
Copyright 2011 SAP AG Complete Copyright Notice