LambdaStage Class
Generic stage executor whose behavior is supplied by user-provided callbacks. More...
Declaration
Included Headers
Base class
| class | StageExecutor |
|
Actor-style executor base class — implement to add a new runtime-graph stage. More... | |
Public Constructors Index
| LambdaStage (LambdaOnInput on_input, LambdaOnTick on_tick={}) | |
|
Construct a LambdaStage. on_input is required; on_tick is optional. More... | |
Public Member Functions Index
| void | set_ports (const StagePorts &ports) override |
|
Capture the runtime ports for forwarding to user callbacks. More... | |
| void | on_input (StageMsg &&msg, std::vector< StageOutMsg > &out) override |
|
Forward the incoming message to the user-supplied input handler. More... | |
| void | on_tick (std::int64_t now_ns, std::vector< StageOutMsg > &out) override |
|
Forward the tick to the user-supplied tick handler if one was provided. More... | |
Private Member Attributes Index
| StagePorts | ports_ |
| LambdaOnInput | on_input_ |
| LambdaOnTick | on_tick_ |
Description
Generic stage executor whose behavior is supplied by user-provided callbacks.
Wraps a LambdaOnInput (required) and an optional LambdaOnTick so callers can express stage logic inline without subclassing StageExecutor. The bound StagePorts is forwarded to each callback so it can resolve port ids by name.
- See Also
- See Also
Definition at line 38 of file LambdaStage.h.
Public Constructors
LambdaStage()
| inline |
Construct a LambdaStage. on_input is required; on_tick is optional.
Definition at line 41 of file LambdaStage.h.
Public Member Functions
on_input()
| inline virtual |
Forward the incoming message to the user-supplied input handler.
Definition at line 54 of file LambdaStage.h.
on_tick()
| inline virtual |
Forward the tick to the user-supplied tick handler if one was provided.
Definition at line 59 of file LambdaStage.h.
set_ports()
| inline virtual |
Capture the runtime ports for forwarding to user callbacks.
Definition at line 49 of file LambdaStage.h.
Private Member Attributes
on_input_
|
Definition at line 66 of file LambdaStage.h.
on_tick_
|
Definition at line 67 of file LambdaStage.h.
ports_
|
Definition at line 65 of file LambdaStage.h.
The documentation for this class was generated from the following file:
Generated via doxygen2docusaurus 2.0.0 by Doxygen 1.9.8.