com.ldodds.slug.framework
Class DelegatingConsumerImpl
java.lang.Object
com.ldodds.slug.framework.config.ComponentImpl
com.ldodds.slug.framework.DelegatingConsumerImpl
- All Implemented Interfaces:
- Component, Consumer, MemoryHolder
- public class DelegatingConsumerImpl
- extends ComponentImpl
- implements Consumer
Implementation of the Consumer
interface that
supports delegating processing of work item results to
a List of Consumers.
Useful when multiple actions should be taken when a particular
work item is completed.
- Author:
- ldodds
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DelegatingConsumerImpl
public DelegatingConsumerImpl()
DelegatingConsumerImpl
public DelegatingConsumerImpl(java.util.List consumers)
consume
public void consume(Task workItem,
java.lang.Object results)
- Specified by:
consume
in interface Consumer
addConsumer
public void addConsumer(Consumer consumer)
setController
public void setController(Controller controller)
- Specified by:
setController
in interface Consumer
setMemory
public void setMemory(Memory memory)
- Specified by:
setMemory
in interface MemoryHolder