All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Member Functions | List of all members
gazebo::common::DiagnosticManager Class Reference

A diagnostic manager class. More...

#include <common/common.hh>

Inheritance diagram for gazebo::common::DiagnosticManager:
Inheritance graph
[legend]

Public Member Functions

DiagnosticTimerPtr CreateTimer (const std::string &_name)
 Create a new timer instance.
 
bool GetEnabled () const
 Get whether the timers are enabled.
 
std::string GetLabel (int _index) const
 Get a label for a timer.
 
Time GetTime (int _index) const
 Get the time of a timer instance.
 
Time GetTime (const std::string &_label) const
 Get a time based on a label.
 
int GetTimerCount () const
 Get the number of timers.
 
void SetEnabled (bool _e)
 Set whether timers are enabled.
 
void TimerStart (DiagnosticTimer *_timer)
 A diagnostic timer has started.
 
void TimerStop (DiagnosticTimer *_timer)
 A diagnostic timer has stopped.
 

Additional Inherited Members

- Static Public Member Functions inherited from SingletonT< T >
static T * Instance ()
 Get an instance of the singleton.
 
- Protected Member Functions inherited from SingletonT< T >
 SingletonT ()
 Constructor.
 
virtual ~SingletonT ()
 Destructor.
 

Detailed Description

A diagnostic manager class.

Member Function Documentation

DiagnosticTimerPtr gazebo::common::DiagnosticManager::CreateTimer ( const std::string &  _name)

Create a new timer instance.

Parameters
[in]_nameName of the timer.
Returns
A pointer to the new diagnostic timer
bool gazebo::common::DiagnosticManager::GetEnabled ( ) const
inline

Get whether the timers are enabled.

Returns
TRue if the timers are enabled
std::string gazebo::common::DiagnosticManager::GetLabel ( int  _index) const

Get a label for a timer.

Parameters
[in]_indexIndex of a timer instance
Returns
Label of the specified timer
Time gazebo::common::DiagnosticManager::GetTime ( int  _index) const

Get the time of a timer instance.

Parameters
[in]_indexThe index of a timer instance
Returns
Time of the specified timer
Time gazebo::common::DiagnosticManager::GetTime ( const std::string &  _label) const

Get a time based on a label.

Parameters
[in]_labelName of the timer instance
Returns
Time of the specified timer
int gazebo::common::DiagnosticManager::GetTimerCount ( ) const

Get the number of timers.

Returns
The number of timers
void gazebo::common::DiagnosticManager::SetEnabled ( bool  _e)
inline

Set whether timers are enabled.

Parameters
[in]_eTrue = timers are enabled
void gazebo::common::DiagnosticManager::TimerStart ( DiagnosticTimer _timer)

A diagnostic timer has started.

Parameters
[in]_timerThe timer to start

Referenced by gazebo::common::DiagnosticTimer::DiagnosticTimer().

void gazebo::common::DiagnosticManager::TimerStop ( DiagnosticTimer _timer)

A diagnostic timer has stopped.

Parameters
[in]_timeThe timer to stop

Referenced by gazebo::common::DiagnosticTimer::~DiagnosticTimer().


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