net.sf.jga.fn.comparison
public class MaxComp<T> extends AbstractBinaryFunctor<T,T,T> implements Serializable
Copyright © 2003 David A. Hall
Nested Class Summary | |
---|---|
interface | MaxComp.Visitor
Interface for classes that may interpret a MaxComp predicate. |
Constructor Summary | |
---|---|
MaxComp(Comparator<T> comp)
Builds the MaxComp predicate using the given Comparator
|
Method Summary | |
---|---|
void | accept(Visitor v)
Calls the Visitor's visit(MaxComp) method, if it
implements the nested Visitor interface. |
T | fn(T x, T y)
Returns the greater of two arguments, or the first if they are equal. |
Comparator<T> | getComparator()
Returns the comparator in use by this functor |
String | toString() |
Throws: IllegalArgumentException if the argument is null
visit(MaxComp)
method, if it
implements the nested Visitor interface.Returns: the greater of two arguments, or the first if they are equal.
Returns: the comparator in use by this functor