A - the argument type.public final class UnaryFunctionUnaryProcedure<A> extends Object implements UnaryProcedure<A>, Serializable
UnaryFunction
to the UnaryProcedure
interface by ignoring the value returned
by the function.
Note that although this class implements
Serializable, a given instance will
only be truly Serializable if the
underlying function is. Attempts to serialize
an instance whose delegate is not
Serializable will result in an exception.| Constructor and Description |
|---|
UnaryFunctionUnaryProcedure(UnaryFunction<? super A,?> function)
Create an
UnaryProcedure wrapping
the given UnaryFunction. |
| Modifier and Type | Method and Description |
|---|---|
static <A> UnaryFunctionUnaryProcedure<A> |
adapt(UnaryFunction<? super A,?> function)
|
boolean |
equals(Object that) |
boolean |
equals(UnaryFunctionUnaryProcedure<?> that)
Learn whether a specified UnaryFunctionUnaryPredicate is equal to this.
|
int |
hashCode() |
void |
run(A obj)
Evaluate my function, but
ignore its returned value. |
String |
toString() |
public UnaryFunctionUnaryProcedure(UnaryFunction<? super A,?> function)
UnaryProcedure wrapping
the given UnaryFunction.function - the UnaryFunction to wrappublic void run(A obj)
Evaluate my function, but
ignore its returned value.
Execute this procedure.run in interface UnaryProcedure<A>obj - an A parameter to this executionpublic boolean equals(UnaryFunctionUnaryProcedure<?> that)
that - the UnaryFunctionUnaryPredicate to testpublic static <A> UnaryFunctionUnaryProcedure<A> adapt(UnaryFunction<? super A,?> function)
null,
UnaryFunction to the
UnaryProcedure interface.
When the given UnaryFunction is null,
returns null.A - the argument type.function - the possibly-null
UnaryFunction to adaptUnaryProcedure wrapping the given
UnaryFunction, or null
if the given UnaryFunction is nullCopyright © 2003-2013 The Apache Software Foundation. All Rights Reserved.