|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object akka.io.AbstractPipePair<CmdAbove,CmdBelow,EvtAbove,EvtBelow>
public abstract class AbstractPipePair<CmdAbove,CmdBelow,EvtAbove,EvtBelow>
Java API: A pair of pipes, one for commands and one for events. Commands travel from top to bottom, events from bottom to top.
PipelineStage
,
AbstractSymmetricPipePair
,
PipePairFactory
Constructor Summary | |
---|---|
AbstractPipePair()
|
Method Summary | ||
---|---|---|
|
dealias(java.lang.Iterable<scala.util.Either<Evt,Cmd>> msg)
INTERNAL API: Dealias a possibly optimized return value such that it can be safely used; this is never needed when only using public API. |
|
scala.util.Either<EvtAbove,CmdBelow> |
makeCommand(CmdBelow cmd)
Helper method for wrapping a command which shall be emitted. |
|
scala.util.Either<EvtAbove,CmdBelow> |
makeEvent(EvtAbove event)
Helper method for wrapping an event which shall be emitted. |
|
abstract java.lang.Iterable<scala.util.Either<EvtAbove,CmdBelow>> |
onCommand(CmdAbove cmd)
Commands reaching this pipe pair are transformed into a sequence of commands for the next or events for the previous stage. |
|
abstract java.lang.Iterable<scala.util.Either<EvtAbove,CmdBelow>> |
onEvent(EvtBelow event)
Events reaching this pipe pair are transformed into a sequence of commands for the next or events for the previous stage. |
|
java.lang.Iterable<scala.util.Either<EvtAbove,CmdBelow>> |
onManagementCommand(java.lang.Object cmd)
Management commands are sent to all stages in a broadcast fashion, conceptually in parallel (but not actually executing a stage reentrantly in case of events or commands being generated in response to a management command). |
|
java.lang.Iterable<scala.util.Either<EvtAbove,CmdBelow>> |
singleCommand(CmdBelow cmd)
Wrap a single command for efficient return to the pipeline’s machinery. |
|
java.lang.Iterable<scala.util.Either<EvtAbove,CmdBelow>> |
singleEvent(EvtAbove evt)
Wrap a single event for efficient return to the pipeline’s machinery. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public AbstractPipePair()
Method Detail |
---|
public abstract java.lang.Iterable<scala.util.Either<EvtAbove,CmdBelow>> onCommand(CmdAbove cmd)
Throwing exceptions within this method will abort processing of the whole pipeline which this pipe pair is part of.
cmd
- the incoming command
makeCommand(CmdBelow)
,
makeEvent(EvtAbove)
public abstract java.lang.Iterable<scala.util.Either<EvtAbove,CmdBelow>> onEvent(EvtBelow event)
Throwing exceptions within this method will abort processing of the whole pipeline which this pipe pair is part of.
cmd
- the incoming command
makeCommand(CmdBelow)
,
makeEvent(EvtAbove)
public java.lang.Iterable<scala.util.Either<EvtAbove,CmdBelow>> onManagementCommand(java.lang.Object cmd)
public scala.util.Either<EvtAbove,CmdBelow> makeCommand(CmdBelow cmd)
public scala.util.Either<EvtAbove,CmdBelow> makeEvent(EvtAbove event)
public java.lang.Iterable<scala.util.Either<EvtAbove,CmdBelow>> singleCommand(CmdBelow cmd)
Right
and an Iterable
by reusing
one such instance within the AbstractPipePair, hence it can be used ONLY ONCE by
each pipeline stage. Prototypic and safe usage looks like this:
final MyResult result = ... ;
return singleCommand(result);
PipelineContext.singleCommand(Cmd)
public java.lang.Iterable<scala.util.Either<EvtAbove,CmdBelow>> singleEvent(EvtAbove evt)
Left
and an Iterable
by reusing
one such instance within the AbstractPipePair, hence it can be used ONLY ONCE by
each pipeline stage. Prototypic and safe usage looks like this:
final MyResult result = ... ;
return singleEvent(result);
PipelineContext.singleEvent(Evt)
public <Cmd,Evt> java.lang.Iterable<scala.util.Either<Evt,Cmd>> dealias(java.lang.Iterable<scala.util.Either<Evt,Cmd>> msg)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |