Variant message publisher implementation. More...
Public Member Functions | |
Impl (ros::NodeHandle &nodeHandle, const MessageType &type, const std::string &topic, size_t queueSize, bool latch=false, const ros::SubscriberStatusCallback &connectCallback=ros::SubscriberStatusCallback()) | |
Constructor. | |
bool | isValid () const |
True, if this publisher implementation is valid. | |
void | publish (const MessageVariant &variant) |
Publish a message variant on the topic associated with this publisher. | |
void | shutdown () |
Perform shutdown of the publisher. | |
~Impl () | |
Destructor. | |
Public Attributes | |
ros::Publisher | publisher |
The ROS publisher. | |
uint32_t | sequenceNumber |
The sequence number associated with this publisher. | |
MessageSerializer | serializer |
The message serializer associated with this publisher. | |
MessageType | type |
The message type associated with this publisher. |
Variant message publisher implementation.
Definition at line 86 of file Publisher.h.
variant_topic_tools::Publisher::Impl::Impl | ( | ros::NodeHandle & | nodeHandle, |
const MessageType & | type, | ||
const std::string & | topic, | ||
size_t | queueSize, | ||
bool | latch = false , |
||
const ros::SubscriberStatusCallback & | connectCallback = ros::SubscriberStatusCallback() |
||
) |
Constructor.
Definition at line 42 of file Publisher.cpp.
Destructor.
Definition at line 64 of file Publisher.cpp.
bool variant_topic_tools::Publisher::Impl::isValid | ( | ) | const |
True, if this publisher implementation is valid.
Definition at line 104 of file Publisher.cpp.
void variant_topic_tools::Publisher::Impl::publish | ( | const MessageVariant & | variant | ) |
Publish a message variant on the topic associated with this publisher.
Definition at line 131 of file Publisher.cpp.
Perform shutdown of the publisher.
Definition at line 124 of file Publisher.cpp.
The ROS publisher.
Definition at line 126 of file Publisher.h.
The sequence number associated with this publisher.
Definition at line 122 of file Publisher.h.
The message serializer associated with this publisher.
Definition at line 118 of file Publisher.h.
The message type associated with this publisher.
Definition at line 114 of file Publisher.h.