|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectnet.sf.jga.fn.Functor<R>
net.sf.jga.fn.UnaryFunctor<T,java.lang.Boolean>
net.sf.jga.fn.logical.UnaryNegate<T>
public class UnaryNegate<T>
Unary Predicate that logically negates the result of a child predicate. Returns true when child predicate p returns false given object argument x.
Copyright © 2002-2005 David A. Hall
| Nested Class Summary | |
|---|---|
static interface |
UnaryNegate.Visitor
Interface for classes that may interpret a UnaryNegate predicate. |
| Constructor Summary | |
|---|---|
UnaryNegate(UnaryFunctor<? super T,java.lang.Boolean> p)
Builds a UnaryNegate predicate wrapping the given Unary Predicate. |
|
| Method Summary | |
|---|---|
void |
accept(Visitor v)
Calls the Visitor's visit(UnaryNegate) method, if it
implements the nested Visitor interface. |
java.lang.Boolean |
fn(T x)
Given argument x, returns true when child predicate p returns false for x, otherwise returns true. |
UnaryFunctor<? super T,java.lang.Boolean> |
getPredicate()
Returns the child predicate. |
java.lang.String |
toString()
|
| Methods inherited from class net.sf.jga.fn.UnaryFunctor |
|---|
bind, bind0th, bindNth, compose, compose, compose, composeNth, composeNth, eval, generate, generateNth |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public UnaryNegate(UnaryFunctor<? super T,java.lang.Boolean> p)
java.lang.IllegalArgumentException - when no child predicate is given| Method Detail |
|---|
public UnaryFunctor<? super T,java.lang.Boolean> getPredicate()
public java.lang.Boolean fn(T x)
fn in class UnaryFunctor<T,java.lang.Boolean>public void accept(Visitor v)
visit(UnaryNegate) method, if it
implements the nested Visitor interface.
accept in interface Visitableaccept in class Functor<java.lang.Boolean>public java.lang.String toString()
toString in class java.lang.Object
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||