.. _program_listing_file_include_agnocast_agnocast.hpp: Program Listing for File agnocast.hpp ===================================== |exhale_lsh| :ref:`Return to documentation for file ` (``include/agnocast/agnocast.hpp``) .. |exhale_lsh| unicode:: U+021B0 .. UPWARDS ARROW WITH TIP LEFTWARDS .. code-block:: cpp #pragma once #include "agnocast/agnocast_callback_info.hpp" #include "agnocast/agnocast_multi_threaded_executor.hpp" #include "agnocast/agnocast_publisher.hpp" #include "agnocast/agnocast_single_threaded_executor.hpp" #include "agnocast/agnocast_subscription.hpp" #include "rclcpp/rclcpp.hpp" #include #include #include #include #include #include #include #include #include #include namespace agnocast { extern "C" void * initialize_agnocast( const uint64_t shm_size, const unsigned char * heaphook_version_ptr, const size_t heaphook_version_str_len); template typename Publisher::SharedPtr create_publisher( rclcpp::Node * node, const std::string & topic_name, const rclcpp::QoS & qos) { PublisherOptions options; return std::make_shared>(node, topic_name, qos, options); } template typename Publisher::SharedPtr create_publisher( rclcpp::Node * node, const std::string & topic_name, const size_t qos_history_depth) { PublisherOptions options; return std::make_shared>( node, topic_name, rclcpp::QoS(rclcpp::KeepLast(qos_history_depth)), options); } template typename Publisher::SharedPtr create_publisher( rclcpp::Node * node, const std::string & topic_name, const rclcpp::QoS & qos, const PublisherOptions & options) { return std::make_shared>(node, topic_name, qos, options); } template typename Publisher::SharedPtr create_publisher( rclcpp::Node * node, const std::string & topic_name, const size_t qos_history_depth, const PublisherOptions & options) { return std::make_shared>( node, topic_name, rclcpp::QoS(rclcpp::KeepLast(qos_history_depth)), options); } template typename Subscription::SharedPtr create_subscription( rclcpp::Node * node, const std::string & topic_name, const rclcpp::QoS & qos, std::function &)> callback) { const agnocast::SubscriptionOptions options; return std::make_shared>(node, topic_name, qos, callback, options); } template typename Subscription::SharedPtr create_subscription( rclcpp::Node * node, const std::string & topic_name, const size_t qos_history_depth, std::function &)> callback) { const agnocast::SubscriptionOptions options; return std::make_shared>( node, topic_name, rclcpp::QoS(rclcpp::KeepLast(qos_history_depth)), callback, options); } template typename Subscription::SharedPtr create_subscription( rclcpp::Node * node, const std::string & topic_name, const rclcpp::QoS & qos, std::function &)> callback, agnocast::SubscriptionOptions options) { return std::make_shared>(node, topic_name, qos, callback, options); } template typename Subscription::SharedPtr create_subscription( rclcpp::Node * node, const std::string & topic_name, const size_t qos_history_depth, std::function &)> callback, agnocast::SubscriptionOptions options) { return std::make_shared>( node, topic_name, rclcpp::QoS(rclcpp::KeepLast(qos_history_depth)), callback, options); } template typename PollingSubscriber::SharedPtr create_subscription( rclcpp::Node * node, const std::string & topic_name, const size_t qos_history_depth) { return std::make_shared>( node, topic_name, rclcpp::QoS(rclcpp::KeepLast(qos_history_depth))); } template typename PollingSubscriber::SharedPtr create_subscription( rclcpp::Node * node, const std::string & topic_name, const rclcpp::QoS & qos) { return std::make_shared>(node, topic_name, qos); } } // namespace agnocast