jconch.pipeline.impl
Class ClosureConsumer
java.lang.Object
jconch.pipeline.PipelineStage
jconch.pipeline.Consumer
jconch.pipeline.impl.ClosureConsumer
public abstract class ClosureConsumer
- extends Consumer
A Closure-based implementation of a Consumer.
Implementation Note: Due to a
failing of generics, there is no type-safety available for this
implementation.
- Author:
- Robert Fischer
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ClosureConsumer
protected ClosureConsumer(Closure sink,
ThreadingModel threading,
PipeLink in)
- Constructor.
- Parameters:
sink - The implementation of the consumption.threading - The model for this consumer to use.in - The link into this stage.
- Throws:
org.apache.commons.lang.NullArgumentException - If any argument is null
consumeItem
public void consumeItem(Object item)
- Delegates implementation to
Closure.execute(Object).
- Specified by:
consumeItem in class Consumer
- Parameters:
item - The item to consume; never null