public static class ConsumerN.Instance extends java.lang.Object implements AbstractConsumerN<ConsumerN.Instance>
AbstractConsumerN which properly defines the
arity of that particular consumer.AbstractConsumerN| Constructor and Description |
|---|
Instance(int arity,
Consumer1<java.lang.Object[]> consumer)
Constructs an instance of the consumer.
|
| Modifier and Type | Method and Description |
|---|---|
void |
acceptAllUnchecked(java.lang.Object... args)
Performs this operation on the given arguments.
|
ConsumerN.Instance |
andThen(ConsumerN.Instance after)
Returns a chained object that performs, in sequence, this operation followed
by the
after operation. |
<V> net.ashwork.functionality.FunctionN.Instance<V> |
andThen(net.ashwork.functionality.Function1<? super java.lang.Void,? extends V> after) |
ConsumerN.Instance |
andThenUnchecked(ConsumerN.Instance after)
Returns a chained object that performs, in sequence, this operation followed
by the
after operation. |
<V> net.ashwork.functionality.FunctionN.Instance<V> |
andThenUnchecked(net.ashwork.functionality.Function1<? super java.lang.Void,? extends V> after) |
int |
arity() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitapplyAllUnchecked, sizedAcceptAllUncheckedpublic Instance(int arity,
Consumer1<java.lang.Object[]> consumer)
arity - the number of arguments of the consumerconsumer - the consumer to be appliedpublic int arity()
arity in interface net.ashwork.functionality.FunctionN<java.lang.Void>arity in interface net.ashwork.functionality.partial.Aritypublic void acceptAllUnchecked(java.lang.Object... args)
AbstractConsumerNacceptAllUnchecked in interface AbstractConsumerN<ConsumerN.Instance>args - the input argumentspublic ConsumerN.Instance andThen(ConsumerN.Instance after)
ConsumerChainableafter operation. If performing either operation throws an
exception, it is relayed to the caller of the composed operation. If performing
this operation throws an exception, the after operation will not be
performed.andThen in interface AbstractConsumerN<ConsumerN.Instance>andThen in interface ConsumerChainable<ConsumerN.Instance>andThen in interface ConsumerChainableConsumer<ConsumerN.Instance>after - the operation to perform after this operationafter operationpublic ConsumerN.Instance andThenUnchecked(ConsumerN.Instance after)
ConsumerChainableafter operation. If performing either operation throws an
exception, it is relayed to the caller of the composed operation. If performing
this operation throws an exception, the after operation will not be
performed. This makes no assumptions on the arguments of this method.andThenUnchecked in interface AbstractConsumerN<ConsumerN.Instance>andThenUnchecked in interface ConsumerChainable<ConsumerN.Instance>andThenUnchecked in interface ConsumerChainableConsumer<ConsumerN.Instance>after - the operation to perform after this operationafter operationpublic <V> net.ashwork.functionality.FunctionN.Instance<V> andThen(net.ashwork.functionality.Function1<? super java.lang.Void,? extends V> after)
andThen in interface net.ashwork.functionality.FunctionN<java.lang.Void>andThen in interface net.ashwork.functionality.partial.ResultChainable<java.lang.Void>andThen in interface net.ashwork.functionality.partial.ResultChainableResult<java.lang.Void>public <V> net.ashwork.functionality.FunctionN.Instance<V> andThenUnchecked(net.ashwork.functionality.Function1<? super java.lang.Void,? extends V> after)
andThenUnchecked in interface net.ashwork.functionality.FunctionN<java.lang.Void>andThenUnchecked in interface net.ashwork.functionality.partial.ResultChainable<java.lang.Void>andThenUnchecked in interface net.ashwork.functionality.partial.ResultChainableResult<java.lang.Void>