groovyx.gpars.dataflow.operator
Class DataflowSelectorActor
java.lang.Object
groovyx.gpars.serial.WithSerialId
groovyx.gpars.actor.impl.MessageStream
groovyx.gpars.actor.Actor
groovyx.gpars.actor.AbstractLoopingActor
groovyx.gpars.actor.StaticDispatchActor<java.lang.Object>
groovyx.gpars.dataflow.operator.DataflowProcessorActor
groovyx.gpars.dataflow.operator.DataflowSelectorActor
- All Implemented Interfaces:
- java.io.Serializable
- Direct Known Subclasses:
- ForkingDataflowSelectorActor
class DataflowSelectorActor
- extends DataflowProcessorActor
An selector's internal actor. Repeatedly polls inputs and once they're all available it performs the selector's body.
Iteratively waits for values on the inputs.
Once all a value is available (received as a message), the selector's body is run.
- Author:
- Vaclav Pech
Method Summary |
(package private) void |
afterStart()
|
private void |
handlePoisonPillInSelector(int index,
java.lang.Object value)
|
void |
onMessage(java.lang.Object message)
All messages unhandled by sub-classes will result in an exception being thrown |
(package private) void |
startTask(int index,
java.lang.Object result)
|
Methods inherited from class groovyx.gpars.actor.AbstractLoopingActor |
getSender, hasBeenStopped, initialize, isActive, isFair, makeFair, reply, replyIfExists, setParallelGroup, setTimeout, silentStart, start, stop, sweepNextMessage, terminate |
Methods inherited from class groovyx.gpars.actor.Actor |
createActorMessage, createRemoteHandle, deregisterCurrentActorWithThread, getJoinLatch, getParallelGroup, handleException, handleInterrupt, handleStart, handleTermination, handleTimeout, isActorThread, join, join, join, join, onStop, registerCurrentActorWithThread, sendAndContinue, sendAndPromise, threadBoundActor |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
passIndex
protected final boolean passIndex
DataflowSelectorActor
DataflowSelectorActor(DataflowSelector owningOperator,
PGroup group,
java.util.List outputs,
java.util.List inputs,
groovy.lang.Closure code)
afterStart
final void afterStart()
- Overrides:
afterStart
in class DataflowProcessorActor
onMessage
public final void onMessage(java.lang.Object message)
- Description copied from class:
DataflowProcessorActor
- All messages unhandled by sub-classes will result in an exception being thrown
- Overrides:
onMessage
in class DataflowProcessorActor
- Parameters:
message
- The unhandled message
handlePoisonPillInSelector
private void handlePoisonPillInSelector(int index,
java.lang.Object value)
startTask
void startTask(int index,
java.lang.Object result)