universe
Class List.GComp<X,Y>

java.lang.Object
  extended by universe.List.GComp<X,Y>
Direct Known Subclasses:
List.Comp
Enclosing class:
List<X>

public abstract static class List.GComp<X,Y>
extends java.lang.Object

(General) Compare two List Elements of possibly different types (true is "LessThan" for sort(), but "Equal" for same(...))


Constructor Summary
List.GComp()
           
 
Method Summary
abstract  boolean comp(X x, Y y)
          Compare these two Xs, returning true/false
 List.Pred<X> curry(Y y)
          Return a Predicate that uses the comparator (later) using the given X as its first argument
 List.GComp<Y,X> flip()
          Return a general comparator with flipped comparision (and types)
 List.Pred<Y> revCurry(X x)
          Return a (reversed) Predicate that uses the comparator (later) using the given Y as its second argument
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

List.GComp

public List.GComp()
Method Detail

comp

public abstract boolean comp(X x,
                             Y y)
Compare these two Xs, returning true/false


flip

public List.GComp<Y,X> flip()
Return a general comparator with flipped comparision (and types)


curry

public List.Pred<X> curry(Y y)
Return a Predicate that uses the comparator (later) using the given X as its first argument


revCurry

public List.Pred<Y> revCurry(X x)
Return a (reversed) Predicate that uses the comparator (later) using the given Y as its second argument