public class NaturalComparator<T extends Comparable<T>> extends Object implements Comparator<T>
Comparator implementation that can be used
when items to compare have "natural" sorting order that
can be used via Comparable interface.| Constructor and Description |
|---|
NaturalComparator() |
| Modifier and Type | Method and Description |
|---|---|
int |
compare(T arg0,
T arg1) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitcomparing, comparing, comparingDouble, comparingInt, comparingLong, equals, naturalOrder, nullsFirst, nullsLast, reversed, reverseOrder, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLongpublic int compare(T arg0, T arg1)
compare in interface Comparator<T extends Comparable<T>>Copyright © 2022 FasterXML. All rights reserved.