finesse.components.node.Node

Overview

class finesse.components.node.Node(name, port, node_type, direction)[source]

Bases: object

Represents a specific connection at a component.

Mathematically a node represents a single equation in the interferometer matrix.

A node can only be owned by a single component instance - with weak references stored by the connected components.

Parameters:
namestr

Name of newly created node.

componentPort

The port that this node belongs to.

node_typeNodeType

Physical node type.

Properties

Node.component

The component which has ownership of this node.

Node.connection

A reference to the Space or Wire object attached to this node.

Node.direction

NodeDirection of this node.

Node.full_name

Full name.

Node.is_input

Flag indicating whether this node is an input to the associated component.

Node.name

Name of the node object.

Node.port

Port this node is attached to.

Node.port_name

Port name.

Node.tag

Tagged name of the node object.

Node.type

NodeType of the node object.

Methods

Node.__init__(name, port, node_type, direction)

Node.is_neighbour(node)

Checks if node is a connected by an edge to this node.