Left - the left sideRight - the right sidepublic class PairComparator<Left,Right> extends Object implements Comparator<Pair<Left,Right>>
| Modifier and Type | Method and Description |
|---|---|
int |
compare(Pair<Left,Right> o1,
Pair<Left,Right> o2) |
static <L,R> PairComparator<L,R> |
createLeftSidePairComparator(Comparator<L> leftComparator)
Creating a constructor for a comparison on the left side of the pair
|
static <L,R> PairComparator<L,R> |
createRightSidePairComparator(Comparator<R> rightComparator)
Creating a constructor for a comparison on the right side of the pair
|
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 static <L,R> PairComparator<L,R> createLeftSidePairComparator(Comparator<L> leftComparator)
L - generic left side objectR - generic right side objectleftComparator - the comparatorpublic static <L,R> PairComparator<L,R> createRightSidePairComparator(Comparator<R> rightComparator)
L - generic left side objectR - generic right side objectrightComparator - the comparatorCopyright © 2019 Communote team. All rights reserved.