kanzi::StopWatch Class Reference

Stop watch class. More...

#include <kanzi/core/time/stop_watch.hpp>

Public Member Functions

 StopWatch ()
 Constructor. More...
 
chrono::milliseconds getDeltaTime ()
 Returns the number of milliseconds since the last call to getDeltaTime(), or the number of milliseconds since the StopWatch was constructed if this is the first call to getDeltaTime(). More...
 
chrono::milliseconds peekDeltaTime () const
 Returns the number of milliseconds since the last call to getDeltaTime(), or the number of milliseconds since the StopWatch was constructed if getDeltaTime() has not been called. More...
 

Protected Attributes

unsigned int m_previousTime
 Time during last update. More...
 

Detailed Description

Stop watch class.

Constructor & Destructor Documentation

kanzi::StopWatch::StopWatch ( )

Constructor.

Member Function Documentation

chrono::milliseconds kanzi::StopWatch::getDeltaTime ( )

Returns the number of milliseconds since the last call to getDeltaTime(), or the number of milliseconds since the StopWatch was constructed if this is the first call to getDeltaTime().

chrono::milliseconds kanzi::StopWatch::peekDeltaTime ( ) const

Returns the number of milliseconds since the last call to getDeltaTime(), or the number of milliseconds since the StopWatch was constructed if getDeltaTime() has not been called.

Member Data Documentation

unsigned int kanzi::StopWatch::m_previousTime
protected

Time during last update.


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