se.lth.cs.nlp.nlputils.core
Class ByRight<T1,T2 extends Comparable<? super T2>>

java.lang.Object
  extended by se.lth.cs.nlp.nlputils.core.ByRight<T1,T2>
All Implemented Interfaces:
Comparator<Pair<T1,T2>>

public class ByRight<T1,T2 extends Comparable<? super T2>>
extends Object
implements Comparator<Pair<T1,T2>>

A comparator that compares the right element of a pair.

Author:
Richard Johansson (richard@cs.lth.se)

Constructor Summary
ByRight()
           
 
Method Summary
 int compare(Pair<T1,T2> p1, Pair<T1,T2> p2)
           
 
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
 

Constructor Detail

ByRight

public ByRight()
Method Detail

compare

public int compare(Pair<T1,T2> p1,
                   Pair<T1,T2> p2)
Specified by:
compare in interface Comparator<Pair<T1,T2 extends Comparable<? super T2>>>