DiagnosticTimer Class Reference

A timer designed for diagnostics. More...

#include <util/util.hh>

Inherits Timer.

Public Member Functions

 DiagnosticTimer (const std::string &_name)
 Constructor. More...
 
virtual ~DiagnosticTimer ()
 Destructor. More...
 
Time GetElapsed () const
 Get the elapsed time. More...
 
const std::string GetName () const GAZEBO_DEPRECATED(7.0)
 Get the name of the timer. More...
 
bool GetRunning () const
 Returns true if the timer is running. More...
 
void Lap (const std::string &_prefix)
 Output a lap time. More...
 
const std::string Name () const
 Get the name of the timer. More...
 
void Reset ()
 Reset the timer. More...
 
virtual void Start ()
 Start the timer. More...
 
virtual void Stop ()
 Stop the timer. More...
 

Detailed Description

A timer designed for diagnostics.

Constructor & Destructor Documentation

§ DiagnosticTimer()

DiagnosticTimer ( const std::string &  _name)

Constructor.

Parameters
[in]_nameName of the timer

§ ~DiagnosticTimer()

virtual ~DiagnosticTimer ( )
virtual

Destructor.

Member Function Documentation

§ GetElapsed()

Time GetElapsed ( ) const
inherited

Get the elapsed time.

Returns
The time

§ GetName()

const std::string GetName ( ) const

Get the name of the timer.

Returns
The name of timer
Deprecated:
See Name() const

§ GetRunning()

bool GetRunning ( ) const
inherited

Returns true if the timer is running.

Returns
Tue if the timer has been started and not stopped.

§ Lap()

void Lap ( const std::string &  _prefix)

Output a lap time.

Parameters
[in]_prefixAnnotation to output with the elapsed time.

§ Name()

const std::string Name ( ) const

Get the name of the timer.

Returns
The name of timer

§ Reset()

void Reset ( )
inherited

Reset the timer.

§ Start()

virtual void Start ( )
virtual

Start the timer.

Reimplemented from Timer.

§ Stop()

virtual void Stop ( )
virtual

Stop the timer.

Reimplemented from Timer.


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