Class CompoundPublisher
Defined in File compound_publisher.hpp
Class Documentation
-
class CompoundPublisher
A compound publisher for the driver’s topics.
This class encapsulates all necessary publishers to keep the driver’s lifecycle management nice and clear.
Public Functions
-
CompoundPublisher(rclcpp_lifecycle::LifecycleNode *node)
-
CompoundPublisher() = delete
-
CompoundPublisher &operator=(CompoundPublisher&&) = delete
-
CompoundPublisher(const CompoundPublisher &other) = delete
-
CompoundPublisher(CompoundPublisher&&) = delete
-
CompoundPublisher &operator=(const CompoundPublisher&) = delete
-
void publish(const std_msgs::msg::Header &header, visionary::SafeVisionaryData &frame_data)
Publish once with all registered publishers.
- Parameters:
header – Header for this data
frame_data – The sensor’s data to publish
-
void activate()
Call this function in the lifecycle node’s
on_activate
.
-
void deactivate()
Call this function in the lifecycle node’s
on_deactivate
.
-
void reset()
Reset all publishers.
This destroys all registered publishers such that their topics are no longer advertised. Call this function in the lifecycle node’s
on_cleanup
andon_shutdown
. It’s save to call this function multiple times.
-
CompoundPublisher(rclcpp_lifecycle::LifecycleNode *node)