Pipeline
- class ioiocore.pipeline.Pipeline(directory=None)[source]
Bases:
InterfaceA class representing a pipeline, inheriting from Interface. Manages nodes and their connections within the pipeline.
- Parameters:
directory (str)
- __init__(directory=None)[source]
Initializes the pipeline.
- Parameters:
directory (str, optional) – Directory to be used for the pipeline (default is None).
- add_node(node)[source]
Adds a node to the pipeline.
- Parameters:
node (Node) – The node to add to the pipeline.
- static deserialize(data)[source]
Deserializes the pipeline from a dictionary.
- Parameters:
data (dict) – A dictionary containing the serialized pipeline data.
- Returns:
The deserialized pipeline object.
- Return type:
- get_condition()[source]
Returns the current condition of the pipeline.
- Returns:
The current condition of the pipeline.
- Return type:
- get_elapsed_time()[source]
Returns the elapsed time since the pipeline started.
- Returns:
The elapsed time in seconds.
- Return type:
float
- get_last_error()[source]
Returns the last error message from the pipeline.
- Returns:
The last error message.
- Return type:
str
- get_state()[source]
Returns the current state of the pipeline.
- Returns:
The current state of the pipeline.
- Return type:
- log(msg, type=None)[source]
Writes a log entry to the pipeline.
- Parameters:
entry (str) – The log entry to write.
msg (str)
type (LogTypes)