nineml.abstraction_layer.component.ComponentQueryer

class nineml.abstraction_layer.component.ComponentQueryer(component)

ComponentQueryer provides a way of adding methods to query a ComponentClass object, without polluting the class

__init__(component)

Constructor for the ComponentQueryer

Methods

__init__(component) Constructor for the ComponentQueryer
get_fully_qualified_port_connections() Used by the flattening code.
regime([name]) Find a regime in the component by name

Attributes

analog_ports_map Returns a map of names to AnalogPort objects
analog_recv_ports Get the recv AnalogPorts
analog_reduce_ports Get the reduce AnalogPorts
analog_send_ports Get the send AnalogPorts
event_ports_map Returns a map of names to EventPort objects
event_recv_ports Get the recv EventPorts
event_send_ports Get the send EventPorts
parameters_map Returns a map of names to Parameter objects
ports Return an iterator over all the port (Event & Analog) in the
recurse_all_components Returns an iterator over this component and all subcomponents
get_fully_qualified_port_connections()

Used by the flattening code.

This method returns a list of tuples of the the fully-qualified port connections. For example, [(“a.b.C”,”d.e.F”),(“g.h.I”,”j.k.L”), ..., (“u.W”,”x.y.Z”) ] but note that it is not string objects that are returned, but NamespaceAddress objects.

regime(name=None)

Find a regime in the component by name

analog_ports_map

Returns a map of names to AnalogPort objects

analog_recv_ports

Get the recv AnalogPorts

analog_reduce_ports

Get the reduce AnalogPorts

analog_send_ports

Get the send AnalogPorts

event_ports_map

Returns a map of names to EventPort objects

event_recv_ports

Get the recv EventPorts

event_send_ports

Get the send EventPorts

parameters_map

Returns a map of names to Parameter objects

ports

Return an iterator over all the port (Event & Analog) in the component

recurse_all_components

Returns an iterator over this component and all subcomponents