ONode

class ioiocore.o_node.ONode(output_ports=None, **kwargs)[source]

Bases: Node

A class representing an output node, inheriting from Node.

Parameters:

output_ports (list)

class Configuration(**kwargs)[source]

Bases: Configuration

Configuration class for ONode.

class Keys[source]

Bases: Keys

Keys for the ONode configuration.

OUTPUT_PORTS = 'output_ports'
__init__(**kwargs)[source]

Initializes the configuration for ONode.

Parameters:

**kwargs (additional keyword arguments) – Other configuration options, including output ports.

__init__(output_ports=None, **kwargs)[source]

Initializes the ONode.

Parameters:
  • output_ports (list of OPort.Configuration, optional) – A list of output port configurations (default is None).

  • **kwargs (additional keyword arguments) – Other configuration options.

config: Configuration
connect(output_port, target, input_port)[source]

Connects an output port to an input port of a target node.

Parameters:
  • output_port (str) – The name of the output port.

  • target (INode) – The target node to which the output port will be connected.

  • input_port (str) – The name of the input port on the target node.

cycle(data={})[source]

Performs a cycle operation on the ONode.

Parameters:

data (dict, optional) – A dictionary containing the data for the cycle operation (default is an empty dictionary).

disconnect(output_port, target, input_port)[source]

Disconnects an output port from an input port of a target node.

Parameters:
  • output_port (str) – The name of the output port.

  • target (INode) – The target node from which the output port will be disconnected.

  • input_port (str) – The name of the input port on the target node.

setup(data, port_metadata_in)[source]

Sets up the ONode.

Parameters:
  • data (dict) – A dictionary containing setup data.

  • port_metadata_in (dict) – A dictionary containing input port metadata.

Returns:

A dictionary containing output port metadata.

Return type:

dict