Class SMSubConfigComparator
- java.lang.Object
-
- com.sun.identity.console.base.model.SMSubConfigComparator
-
- All Implemented Interfaces:
Comparator
public class SMSubConfigComparator extends Object implements Comparator
Sub Configuration Display Object Comparator.
-
-
Constructor Summary
Constructors Constructor Description SMSubConfigComparator(Collator collator)Creates an instance ofSMSubConfigComparator.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intcompare(Object o1, Object o2)Compares twoSMSubConfigobject.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface java.util.Comparator
equals, reversed, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLong
-
-
-
-
Constructor Detail
-
SMSubConfigComparator
public SMSubConfigComparator(Collator collator)
Creates an instance ofSMSubConfigComparator.- Parameters:
collator- for locale base sorting
-
-
Method Detail
-
compare
public int compare(Object o1, Object o2)
Compares twoSMSubConfigobject. Ordered by its type and then name.- Specified by:
comparein interfaceComparator- Returns:
- 0 if their types and names are the same.
-1 if
o1's type is lexicographically less thano2's type. compares their name if their type is the same. 1 ifo2's type is lexicographically less thano2's type. compares their name if their type is the same.
-
-