33 friend class RosActionNode;
35 friend class RosServiceNode;
37 friend class RosSubscriberNode;
39 friend class RosPublisherNode;
51 rclcpp::Node::SharedPtr ros_node, rclcpp::CallbackGroup::SharedPtr tree_node_waitables_callback_group,
52 rclcpp::executors::SingleThreadedExecutor::SharedPtr tree_node_waitables_executor,
95 BT::Expected<std::string> getCommunicationPortName(
const BT::TreeNode * node)
const;
97 const std::string ros_node_name_;
98 const std::string fully_qualified_ros_node_name_;
99 rclcpp::Logger base_logger_;
102 rclcpp::Node::WeakPtr nh_;
104 rclcpp::CallbackGroup::WeakPtr cb_group_;
106 rclcpp::executors::SingleThreadedExecutor::WeakPtr executor_;
std::string getROSNodeName() const
Get the name of the ROS 2 node passed to the constructor.
rclcpp::Logger getChildLogger(const std::string &name)
Get a child logger created using the associated ROS 2 node.
rclcpp::Time getCurrentTime() const
Get the current time using the associated ROS 2 node.
RosNodeContext(rclcpp::Node::SharedPtr ros_node, rclcpp::CallbackGroup::SharedPtr tree_node_waitables_callback_group, rclcpp::executors::SingleThreadedExecutor::SharedPtr tree_node_waitables_executor, const NodeRegistrationOptions &options)
Constructor.
std::string getFullyQualifiedTreeNodeName(const BT::TreeNode *node, bool with_class_name=true) const
Create a string representing the detailed name of a behavior tree node.
std::string getFullyQualifiedRosNodeName() const
Get the fully qualified name of the ROS 2 node passed to the constructor.
rclcpp::Logger getBaseLogger() const
Get the logger of the associated ROS 2 node.