as2fm.scxml_converter.scxml_entries.scxml_ros_field.RosField

class as2fm.scxml_converter.scxml_entries.scxml_ros_field.RosField(name: str, expr: BtGetValueInputPort | str)

Bases: ScxmlParam

Field of a ROS msg published in a topic.

__init__(name: str, expr: BtGetValueInputPort | str)

Initialize the SCXML Parameter object.

The location entryu is kept for consistency, but using expr achieves the same result.

Parameters:
  • name – The name of the parameter.

  • expr – The expression to assign to the parameter. Can come from a BT port.

  • location – The expression to assign to the parameter, if that’s a data variable.

Methods

__init__(name, expr)

Initialize the SCXML Parameter object.

as_plain_scxml(_)

Convert the object to its plain SCXML version.

as_xml()

Convert the object to an XML element.

check_validity()

Check if the object is valid.

from_xml_tree(xml_tree)

Create a RosField object from an XML tree.

get_body()

Get the body of the object.

get_data_model()

Get the data model of the object.

get_expr()

get_id()

Get the ID of the object.

get_location()

get_name()

get_states()

Get the states of the object.

get_tag_name()

Get the tag name of the XML element.

set_callback_type(cb_type)

update_bt_ports_values(bt_ports_handler)

Update the values of potential entries making use of BT ports.

as_plain_scxml(_) ScxmlParam

Convert the object to its plain SCXML version.

as_xml() Element

Convert the object to an XML element.

check_validity() bool

Check if the object is valid.

static from_xml_tree(xml_tree: Element) RosField

Create a RosField object from an XML tree.

get_body()

Get the body of the object.

get_data_model()

Get the data model of the object.

get_id() str

Get the ID of the object.

get_states()

Get the states of the object.

static get_tag_name() str

Get the tag name of the XML element.

update_bt_ports_values(bt_ports_handler: BtPortsHandler)

Update the values of potential entries making use of BT ports.