rclcpp
master
C++ ROS Client Library API
|
Go to the documentation of this file.
15 #ifndef RCLCPP__NODE_INTERFACES__NODE_GRAPH_HPP_
16 #define RCLCPP__NODE_INTERFACES__NODE_GRAPH_HPP_
38 namespace graph_listener
43 namespace node_interfaces
102 rclcpp::Event::SharedPtr
108 rclcpp::Event::SharedPtr event,
119 bool no_mangle =
false)
const override;
125 bool no_mangle =
false)
const override;
136 std::atomic_bool should_add_to_graph_listener_;
146 std::atomic_size_t graph_users_count_;
152 #endif // RCLCPP__NODE_INTERFACES__NODE_GRAPH_HPP_
rclcpp::Event::SharedPtr get_graph_event() override
Return a graph event, which will be set anytime a graph change occurs.
std::map< std::string, std::vector< std::string > > get_service_names_and_types_by_node(const std::string &node_name, const std::string &namespace_) const override
Return a map of existing service names to list of service types for a specific node.
size_t count_publishers(const std::string &topic_name) const override
Return the number of publishers that are advertised on a given topic.
#define RCLCPP_DISABLE_COPY(...)
Definition: macros.hpp:26
#define RCLCPP_SMART_PTR_ALIASES_ONLY(...)
Definition: macros.hpp:66
std::map< std::string, std::vector< std::string > > get_service_names_and_types() const override
Return a map of existing service names to list of service types.
std::vector< rclcpp::TopicEndpointInfo > get_subscriptions_info_by_topic(const std::string &topic_name, bool no_mangle=false) const override
Return the topic endpoint information about subscriptions on a given topic.
This header provides the get_node_base_interface() template function.
Definition: allocator_common.hpp:24
std::map< std::string, std::vector< std::string > > get_topic_names_and_types(bool no_demangle=false) const override
Return a map of existing topic names to list of topic types.
#define RCLCPP_PUBLIC
Definition: visibility_control.hpp:50
Pure virtual interface class for the NodeBase part of the Node API.
Definition: node_base_interface.hpp:36
size_t count_graph_users() const override
Return the number of on loan graph events, see get_graph_event().
Implementation the NodeGraph part of the Node API.
Definition: node_graph.hpp:47
std::vector< rclcpp::TopicEndpointInfo > get_publishers_info_by_topic(const std::string &topic_name, bool no_mangle=false) const override
Return the topic endpoint information about publishers on a given topic.
const rcl_guard_condition_t * get_graph_guard_condition() const override
Return the rcl guard condition which is triggered when the ROS graph changes.
void wait_for_graph_change(rclcpp::Event::SharedPtr event, std::chrono::nanoseconds timeout) override
Wait for a graph event to occur by waiting on an Event to become set.
void notify_shutdown() override
Notify any and all blocking node actions that shutdown has occurred.
NodeGraph(rclcpp::node_interfaces::NodeBaseInterface *node_base)
std::vector< std::pair< std::string, std::string > > get_node_names_and_namespaces() const override
Return a vector of existing node names and namespaces (pair of string).
std::vector< std::string > get_node_names() const override
Return a vector of existing node names (string).
Pure virtual interface class for the NodeGraph part of the Node API.
Definition: node_graph_interface.hpp:136
void notify_graph_change() override
Notify threads waiting on graph changes.
size_t count_subscribers(const std::string &topic_name) const override
Return the number of subscribers who have created a subscription for a given topic.