public class ListComparator extends Object implements Comparator, Serializable
| Constructor and Description |
|---|
ListComparator() |
| Modifier and Type | Method and Description |
|---|---|
int |
compare(Object o1,
Object o2)
Compare two lists of Comparable objects.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitequalspublic int compare(Object o1, Object o2)
compare in interface Comparatoro1 - the first object to be compared.o2 - the second object to be compared.ClassCastException - if any of the lists contains an object that
is not Comparable.