Public Member Functions | Private Attributes | List of all members
diagnostic_updater::TopicDiagnostic Class Reference

A class to facilitate making diagnostics for a topic using a FrequencyStatus and TimeStampStatus. More...

#include <publisher.h>

Inheritance diagram for diagnostic_updater::TopicDiagnostic:
Inheritance graph
[legend]

Public Member Functions

virtual void tick ()
 
virtual void tick (const ros::Time &stamp)
 Collects statistics and publishes the message. More...
 
 TopicDiagnostic (std::string name, diagnostic_updater::Updater &diag, const diagnostic_updater::FrequencyStatusParam &freq, const diagnostic_updater::TimeStampStatusParam &stamp)
 Constructs a TopicDiagnostic. More...
 
virtual ~TopicDiagnostic ()
 
- Public Member Functions inherited from diagnostic_updater::HeaderlessTopicDiagnostic
virtual void clear_window ()
 Clears the frequency statistics. More...
 
 HeaderlessTopicDiagnostic (std::string name, diagnostic_updater::Updater &diag, const diagnostic_updater::FrequencyStatusParam &freq)
 Constructs a HeaderlessTopicDiagnostic. More...
 
virtual ~HeaderlessTopicDiagnostic ()
 
- Public Member Functions inherited from diagnostic_updater::CompositeDiagnosticTask
void addTask (DiagnosticTask *t)
 Adds a child CompositeDiagnosticTask. More...
 
 CompositeDiagnosticTask (const std::string name)
 Constructs a CompositeDiagnosticTask with the given name. More...
 
virtual void run (DiagnosticStatusWrapper &stat)
 Runs each child and merges their outputs. More...
 
- Public Member Functions inherited from diagnostic_updater::DiagnosticTask
 DiagnosticTask (const std::string name)
 Constructs a DiagnosticTask setting its name in the process. More...
 
const std::string & getName ()
 Returns the name of the DiagnosticTask. More...
 
virtual ~DiagnosticTask ()
 

Private Attributes

TimeStampStatus stamp_
 

Detailed Description

A class to facilitate making diagnostics for a topic using a FrequencyStatus and TimeStampStatus.

Definition at line 111 of file publisher.h.

Constructor & Destructor Documentation

◆ TopicDiagnostic()

diagnostic_updater::TopicDiagnostic::TopicDiagnostic ( std::string  name,
diagnostic_updater::Updater diag,
const diagnostic_updater::FrequencyStatusParam freq,
const diagnostic_updater::TimeStampStatusParam stamp 
)
inline

Constructs a TopicDiagnostic.

Parameters
nameThe name of the topic that is being diagnosed.
diagThe diagnostic_updater that the CompositeDiagnosticTask should add itself to.
freqThe parameters for the FrequencyStatus class that will be computing statistics.
stampThe parameters for the TimeStampStatus class that will be computing statistics.

Definition at line 129 of file publisher.h.

◆ ~TopicDiagnostic()

virtual diagnostic_updater::TopicDiagnostic::~TopicDiagnostic ( )
inlinevirtual

Definition at line 140 of file publisher.h.

Member Function Documentation

◆ tick() [1/2]

virtual void diagnostic_updater::TopicDiagnostic::tick ( )
inlinevirtual

This method should never be called on a TopicDiagnostic as a timestamp is needed to collect the timestamp diagnostics. It is defined here to prevent the inherited tick method from being used accidentally.

Reimplemented from diagnostic_updater::HeaderlessTopicDiagnostic.

Definition at line 148 of file publisher.h.

◆ tick() [2/2]

virtual void diagnostic_updater::TopicDiagnostic::tick ( const ros::Time stamp)
inlinevirtual

Collects statistics and publishes the message.

Parameters
stampTimestamp to use for interval computation by the TimeStampStatus class.

Definition at line 156 of file publisher.h.

Member Data Documentation

◆ stamp_

TimeStampStatus diagnostic_updater::TopicDiagnostic::stamp_
private

Definition at line 163 of file publisher.h.


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


diagnostic_updater
Author(s): Kevin Watts, Brice Rebsamen , Jeremy Leibs, Blaise Gassend
autogenerated on Mon Feb 28 2022 22:18:16