Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
locomotor::Executor Class Reference

Collection of objects used in ROS CallbackQueue threading. More...

#include <executor.h>

Public Member Functions

void addCallback (LocomotorCallback::Function f)
 Add a callback to this executor's CallbackQueue. More...
 
 Executor (const ros::NodeHandle &base_nh, bool create_cb_queue=true)
 Constructor. Creates new CallbackQueue or uses global CallbackQueue. More...
 
virtual const ros::NodeHandlegetNodeHandle () const
 Gets NodeHandle coupled with this executor's CallbackQueue. More...
 
virtual ~Executor ()
 

Protected Member Functions

virtual ros::CallbackQueuegetQueue ()
 Gets the queue for this executor. More...
 

Protected Attributes

ros::NodeHandle ex_nh_
 
std::shared_ptr< ros::CallbackQueuequeue_
 
std::shared_ptr< ros::AsyncSpinnerspinner_
 

Detailed Description

Collection of objects used in ROS CallbackQueue threading.

This light wrapper around the contained classes allows for intelligent cleanup of the objects

Definition at line 71 of file executor.h.

Constructor & Destructor Documentation

locomotor::Executor::Executor ( const ros::NodeHandle base_nh,
bool  create_cb_queue = true 
)
explicit

Constructor. Creates new CallbackQueue or uses global CallbackQueue.

Parameters
base_nhBase NodeHandle that this executor's NodeHandle will be derived from
create_cb_queueIf true, creates a new CallbackQueue. If false, uses global CallbackQueue

Definition at line 39 of file executor.cpp.

virtual locomotor::Executor::~Executor ( )
inlinevirtual

Definition at line 81 of file executor.h.

Member Function Documentation

void locomotor::Executor::addCallback ( LocomotorCallback::Function  f)

Add a callback to this executor's CallbackQueue.

Parameters
fLocomotorCallback

Definition at line 64 of file executor.cpp.

const ros::NodeHandle & locomotor::Executor::getNodeHandle ( ) const
virtual

Gets NodeHandle coupled with this executor's CallbackQueue.

Definition at line 59 of file executor.cpp.

ros::CallbackQueue & locomotor::Executor::getQueue ( )
protectedvirtual

Gets the queue for this executor.

Definition at line 69 of file executor.cpp.

Member Data Documentation

ros::NodeHandle locomotor::Executor::ex_nh_
protected

Definition at line 101 of file executor.h.

std::shared_ptr<ros::CallbackQueue> locomotor::Executor::queue_
protected

Definition at line 99 of file executor.h.

std::shared_ptr<ros::AsyncSpinner> locomotor::Executor::spinner_
protected

Definition at line 100 of file executor.h.


The documentation for this class was generated from the following files:


locomotor
Author(s):
autogenerated on Wed Jun 26 2019 20:06:18