titanfe.brick module¶
Abstract base classes for building Bricks
-
class
titanfe.brick.
BrickBase
(adapter: titanfe.apps.brick_runner.adapter.BrickAdapter, parameters: Optional[Dict] = None)[source]¶ Bases:
object
An abstract base class for building Bricks
-
abstract
process
(input: Type[ujotypes.variants.base.UjoBase], port: str)[source]¶ Do the input processing.
To modify the payload of the current packet simply return a new value. Use the adapter’s emit_new_packet to create a data packet and insert it into the flow.
- Parameters:
input (Type[UjoBase]) – the input data to be processed
- Returns:
the new payload for current data packet traveling in the flow. When returning None the current packet get’s dropped.
- Return type:
Optional[UjoBase]
-
abstract
-
class
titanfe.brick.
InletBrickBase
(adapter: titanfe.apps.brick_runner.adapter.BrickAdapter, parameters: Optional[Dict] = None)[source]¶ Bases:
titanfe.brick.BrickBase
An abstract base class for building bricks that will run a continous process