net.sf.jga.fn.adaptor
Class Project2nd<T1,T2>
java.lang.Object
net.sf.jga.fn.Functor<R>
net.sf.jga.fn.BinaryFunctor<T1,T2,T2>
net.sf.jga.fn.adaptor.Project2nd<T1,T2>
- All Implemented Interfaces:
- java.io.Serializable, Visitable
public class Project2nd<T1,T2>
- extends BinaryFunctor<T1,T2,T2>
Binary Functor that returns the second of two runtime arguments.
Copyright © 2002-2005 David A. Hall
- Author:
- David A. Hall
- See Also:
- Serialized Form
Nested Class Summary |
static interface |
Project2nd.Visitor
Interface for classes that may interpret an Project2nd functor. |
Method Summary |
void |
accept(Visitor v)
Calls the Visitor's visit(Project2nd) method, if it
implements the nested Visitor interface. |
T2 |
fn(T1 unused,
T2 y)
Given two arguments, returns the second. |
java.lang.String |
toString()
|
Methods inherited from class net.sf.jga.fn.BinaryFunctor |
bind, bind0th, bind1st, bind2nd, bindNth, compose, compose, composeNth, distribute, eval, generate, generate1st, generate2nd, generateNth |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Project2nd
public Project2nd()
fn
public T2 fn(T1 unused,
T2 y)
- Given two arguments, returns the second. The first argument is not
evaluated in any way by this predicate.
- Specified by:
fn
in class BinaryFunctor<T1,T2,T2>
- Returns:
- x
accept
public void accept(Visitor v)
- Calls the Visitor's
visit(Project2nd)
method, if it
implements the nested Visitor interface.
- Specified by:
accept
in interface Visitable
- Overrides:
accept
in class Functor<T2>
toString
public java.lang.String toString()
- Overrides:
toString
in class java.lang.Object
Copyright © 2002-2006 David A. Hall. All Rights Reserved.