Specialization of the RMWrapper, where the managed resource is ManagedSubscriber. More...
#include <resource_manager.h>
Public Member Functions | |
template<typename... Args> | |
ManagedSubscriber::SharedPtr | subscribe (Args &&...args) |
Adds a subscriber to the list of managed subscribers. More... | |
Public Member Functions inherited from robot_activity::resource::ResourceManager< ManagedSubscriber > | |
void | acquireAll (const ros::NodeHandlePtr &node_handle) |
Acquires all managed resources. More... | |
ManagedSubscriber::SharedPtr | add (Args &&...args) |
Adds a managed resource. More... | |
void | pauseAll () |
Pauses all managed resources. More... | |
void | releaseAll () |
Releases all managed resources. More... | |
ResourceManager () | |
Default constructor. More... | |
void | resumeAll () |
Resumes all managed resources. More... | |
~ResourceManager () | |
Default destructor. More... | |
Specialization of the RMWrapper, where the managed resource is ManagedSubscriber.
Definition at line 141 of file resource_manager.h.
|
inline |
Adds a subscriber to the list of managed subscribers.
However, it does not actually subscribe to the ROS topic, this is deferred until acquireAll is called, where all managed subscribers will be actually subscribed. The goal is to allow user write code as close as possible to the original roscpp API.
args | Arguments describing the ROS subscriber, same as arguments passed to ros::NodeHandle::subscribe |
Definition at line 159 of file resource_manager.h.