SwitchUIPrimaryView Class
Switches the primary view in the MoveIt Studio Developer Tool. More...
Declaration
Included Headers
Base class
| class | SharedResourcesNode<BehaviorTreeNodeT> |
|
The SharedResourcesNode class provides a BehaviorContext object when constructing a BehaviorTree.Cpp node. More... | |
Public Constructors Index
| SwitchUIPrimaryView (const std::string &name, const BT::NodeConfiguration &config, const std::shared_ptr< BehaviorContext > &shared_resources) | |
Public Member Functions Index
| BT::NodeStatus | tick () override |
|
Publishes the requested view name to the UI topic. More... | |
Private Member Attributes Index
| rclcpp::Publisher< std_msgs::msg::String >::SharedPtr | publisher_ |
|
Publisher for the primary view request topic. More... | |
Public Static Functions Index
| static BT::PortsList | providedPorts () |
|
Required implementation of the static providedPorts function. More... | |
| static BT::KeyValueVector | metadata () |
|
Adds metadata, such as description and subcategory, to the Behavior. More... | |
Description
Switches the primary view in the MoveIt Studio Developer Tool.
This can be "Visualization", "Behavior Tree", or the name of any valid camera topic available in the view dropdown menu in the UI.
This behavior publishes the requested view name to a topic, allowing the frontend to update when ready. This is a fire-and-forget operation - the behavior returns SUCCESS immediately after publishing.
The behavior cannot detect or report errors if the view name is invalid or does not exist in the UI. SUCCESS is returned regardless of whether the UI can successfully switch to the requested view.
| Data Port Name | Port Type | Object Type |
|---|---|---|
| primary_view_name | input | std::string |
Definition at line 32 of file switch_ui_primary_view.hpp.
Public Constructors
SwitchUIPrimaryView()
| explicit |
Declaration at line 35 of file switch_ui_primary_view.hpp, definition at line 35 of file switch_ui_primary_view.cpp.
Public Member Functions
tick()
|
Publishes the requested view name to the UI topic.
- Returns
SUCCESS after publishing, FAILURE if input port is invalid.
Declaration at line 53 of file switch_ui_primary_view.hpp, definition at line 54 of file switch_ui_primary_view.cpp.
Private Member Attributes
publisher_
|
Publisher for the primary view request topic.
Definition at line 57 of file switch_ui_primary_view.hpp.
Public Static Functions
metadata()
| static |
Adds metadata, such as description and subcategory, to the Behavior.
Declaration at line 47 of file switch_ui_primary_view.hpp, definition at line 49 of file switch_ui_primary_view.cpp.
providedPorts()
| static |
Required implementation of the static providedPorts function.
- Returns
The list of input and output ports used by this Behavior.
Declaration at line 42 of file switch_ui_primary_view.hpp, definition at line 43 of file switch_ui_primary_view.cpp.
The documentation for this class was generated from the following files:
Generated via doxygen2docusaurus 2.2.2 by Doxygen 1.9.8.