rclcpp
master
C++ ROS Client Library API
|
Factory containing a function used to create a Subscription<MessageT>. More...
#include <subscription_factory.hpp>
Public Types | |
using | SubscriptionFactoryFunction = std::function< rclcpp::SubscriptionBase::SharedPtr(rclcpp::node_interfaces::NodeBaseInterface *node_base, const std::string &topic_name, const rclcpp::QoS &qos)> |
Public Attributes | |
const SubscriptionFactoryFunction | create_typed_subscription |
Factory containing a function used to create a Subscription<MessageT>.
This factory class is used to encapsulate the template generated function which is used during the creation of a Message type specific subscription within a non-templated class.
It is created using the create_subscription_factory function, which is usually called from a templated "create_subscription" method of the Node class, and is passed to the non-templated "create_subscription" method of the NodeTopics class where it is used to create and setup the Subscription.
It also handles the two step construction of Subscriptions, first calling the constructor and then the post_init_setup() method.
using rclcpp::SubscriptionFactory::SubscriptionFactoryFunction = std::function< rclcpp::SubscriptionBase::SharedPtr( rclcpp::node_interfaces::NodeBaseInterface * node_base, const std::string & topic_name, const rclcpp::QoS & qos)> |
const SubscriptionFactoryFunction rclcpp::SubscriptionFactory::create_typed_subscription |