as2fm.scxml_converter.scxml_entries.scxml_bt_ticks.BtChildStatus
- class as2fm.scxml_converter.scxml_entries.scxml_bt_ticks.BtChildStatus(child_seq_id: str | int, target: str, condition: str | None = None, body: List[ScxmlAssign | ScxmlIf | ScxmlSend] | None = None)
Bases:
ScxmlTransition
Process the response received from a BT child.
- __init__(child_seq_id: str | int, target: str, condition: str | None = None, body: List[ScxmlAssign | ScxmlIf | ScxmlSend] | None = None)
Generate a BtChildStatus instance.
- Parameters:
child_seq_id – Which BT control node children to tick (relative the the BT-XML file).
target – The target state to transition to.
condition – The condition to check before transitioning.
body – The body to execute before the transition.
Methods
__init__
(child_seq_id, target[, condition, body])Generate a BtChildStatus instance.
add_event
(event)append_body_executable_entry
(exec_entry)as_plain_scxml
(ros_declarations)Convert the object to its plain SCXML version.
as_xml
()Convert the object to an XML element.
check_valid_ros_instantiations
(ros_declarations)Check if the ros instantiations have been declared.
Check if the object is valid.
from_xml_tree
(xml_tree)Create a ScxmlTransition object from an XML tree.
get_body
()Return the executable content of this transition.
Return the condition required to execute this transition (if any).
Get the data model of the object.
Return the events that trigger this transition (if any).
get_id
()Get the ID of the object.
Get the states of the object.
Get the tag name of the XML element.
Return the ID of the target state of this transition.
instantiate_bt_events
(instance_id, children_ids)Instantiate the BT events of this transition.
set_body
(body)Set the body of this transition.
set_thread_id
(thread_id)Set the thread ID for the executable entries of this transition.
update_bt_ports_values
(bt_ports_handler)Update the values of potential entries making use of BT ports.
- as_plain_scxml(ros_declarations: ScxmlRosDeclarationsContainer) ScxmlTransition
Convert the object to its plain SCXML version.
- as_xml() Element
Convert the object to an XML element.
- check_valid_ros_instantiations(ros_declarations: ScxmlRosDeclarationsContainer) bool
Check if the ros instantiations have been declared.
- check_validity() bool
Check if the object is valid.
- static from_xml_tree(xml_tree)
Create a ScxmlTransition object from an XML tree.
- get_body() List[ScxmlAssign | ScxmlIf | ScxmlSend]
Return the executable content of this transition.
- get_condition() str | None
Return the condition required to execute this transition (if any).
- get_data_model()
Get the data model of the object.
- get_events() List[str]
Return the events that trigger this transition (if any).
- 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.
- get_target_state_id() str
Return the ID of the target state of this transition.
- instantiate_bt_events(instance_id: int, children_ids: List[int]) List[ScxmlTransition]
Instantiate the BT events of this transition.
- set_body(body: List[ScxmlAssign | ScxmlIf | ScxmlSend]) None
Set the body of this transition.
- set_thread_id(thread_id: int) None
Set the thread ID for the executable entries of this transition.
- update_bt_ports_values(bt_ports_handler: BtPortsHandler) None
Update the values of potential entries making use of BT ports.