$search
A TopicDiagnostic combined with a ros::Publisher. More...
#include <publisher.h>
Public Member Functions | |
DiagnosedPublisher (const ros::Publisher &pub, diagnostic_updater::Updater &diag, const diagnostic_updater::FrequencyStatusParam &freq, const diagnostic_updater::TimeStampStatusParam &stamp) | |
Constructs a DiagnosedPublisher. | |
ros::Publisher | getPublisher () const |
Returns the publisher. | |
virtual void | publish (const T &message) |
Collects statistics and publishes the message. | |
virtual void | publish (const boost::shared_ptr< T > &message) |
Collects statistics and publishes the message. | |
void | setPublisher (ros::Publisher pub) |
Changes the publisher. | |
virtual | ~DiagnosedPublisher () |
Private Attributes | |
ros::Publisher | publisher_ |
A TopicDiagnostic combined with a ros::Publisher.
For a standard ros::Publisher, this class allows the ros::Publisher and the TopicDiagnostic to be combined for added convenience.
Definition at line 174 of file publisher.h.
diagnostic_updater::DiagnosedPublisher< T >::DiagnosedPublisher | ( | const ros::Publisher & | pub, | |
diagnostic_updater::Updater & | diag, | |||
const diagnostic_updater::FrequencyStatusParam & | freq, | |||
const diagnostic_updater::TimeStampStatusParam & | stamp | |||
) | [inline] |
Constructs a DiagnosedPublisher.
pub | The publisher on which statistics are being collected. | |
diag | The diagnostic_updater that the CompositeDiagnosticTask should add itself to. | |
freq | The parameters for the FrequencyStatus class that will be computing statistics. | |
stamp | The parameters for the TimeStampStatus class that will be computing statistics. |
Definition at line 192 of file publisher.h.
virtual diagnostic_updater::DiagnosedPublisher< T >::~DiagnosedPublisher | ( | ) | [inline, virtual] |
Definition at line 200 of file publisher.h.
ros::Publisher diagnostic_updater::DiagnosedPublisher< T >::getPublisher | ( | ) | const [inline] |
Returns the publisher.
Definition at line 224 of file publisher.h.
virtual void diagnostic_updater::DiagnosedPublisher< T >::publish | ( | const T & | message | ) | [inline, virtual] |
Collects statistics and publishes the message.
The timestamp to be used by the TimeStampStatus class will be extracted from message.header.stamp.
Definition at line 218 of file publisher.h.
virtual void diagnostic_updater::DiagnosedPublisher< T >::publish | ( | const boost::shared_ptr< T > & | message | ) | [inline, virtual] |
Collects statistics and publishes the message.
The timestamp to be used by the TimeStampStatus class will be extracted from message.header.stamp.
Definition at line 209 of file publisher.h.
void diagnostic_updater::DiagnosedPublisher< T >::setPublisher | ( | ros::Publisher | pub | ) | [inline] |
Changes the publisher.
Definition at line 232 of file publisher.h.
ros::Publisher diagnostic_updater::DiagnosedPublisher< T >::publisher_ [private] |
Definition at line 238 of file publisher.h.