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

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

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

A comparator that compares the left element of a pair.

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

Constructor Summary
ByLeft()
           
 
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

ByLeft

public ByLeft()
Method Detail

compare

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