
FIRST - first typeSECOND - second typepublic static class PairUtil.Compare<FIRST,SECOND> extends Object implements Comparator<Pair<? extends FIRST,? extends SECOND>>
| Modifier and Type | Field and Description | 
|---|---|
private Comparator<? super FIRST> | 
fcomparator
A comparator for type FIRST. 
 | 
private Comparator<? super SECOND> | 
scomparator
A comparator for type FIRST. 
 | 
| Constructor and Description | 
|---|
PairUtil.Compare(Comparator<? super FIRST> fcomparator,
                Comparator<? super SECOND> scomparator)
Provides a comparator for an  
Pair based on the given Comparator
 for type P. | 
| Modifier and Type | Method and Description | 
|---|---|
int | 
compare(Pair<? extends FIRST,? extends SECOND> o1,
       Pair<? extends FIRST,? extends SECOND> o2)
Two Objects of type  
Pair are compared based on the comparison of
 their property using the comparators fcomparator, then
 scomparator. | 
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitequalsprivate Comparator<? super FIRST> fcomparator
private Comparator<? super SECOND> scomparator
public PairUtil.Compare(Comparator<? super FIRST> fcomparator, Comparator<? super SECOND> scomparator)
Pair based on the given Comparator
 for type P.fcomparator - Comparator for the first componentscomparator - Comparator for the second componentpublic int compare(Pair<? extends FIRST,? extends SECOND> o1, Pair<? extends FIRST,? extends SECOND> o2)
Pair are compared based on the comparison of
 their property using the comparators fcomparator, then
 scomparator.compare in interface Comparator<Pair<? extends FIRST,? extends SECOND>>o1 - First objecto2 - Second objectComparator.compare(T, T)