ROS 2 rclcpp + rcl - rolling  rolling-a919a6e5
ROS 2 C++ Client Library with ROS Client Library
Public Types | List of all members
rclcpp::ImplicitTypeAdapter< CustomType > Struct Template Reference

Implicit type adapter used as a short hand way to create something with just the custom type. More...

#include <rclcpp/type_adapter.hpp>

Public Types

using is_specialized = std::false_type
 

Detailed Description

template<typename CustomType>
struct rclcpp::ImplicitTypeAdapter< CustomType >

Implicit type adapter used as a short hand way to create something with just the custom type.

This is used when creating a publisher or subscription using just the custom type in conjunction with RCLCPP_USING_CUSTOM_TYPE_AS_ROS_MESSAGE_TYPE(). For example:

#include "type_adapter_for_std_string_to_std_msgs_String.hpp"

RCLCPP_USING_CUSTOM_TYPE_AS_ROS_MESSAGE_TYPE(std::string, std_msgs::msg::String);

int main(...) {
  // ...
  auto pub = node->create_publisher<std::string>(...);
}
See also
TypeAdapter for more examples.

Definition at line 162 of file type_adapter.hpp.


The documentation for this struct was generated from the following file: