Cogs.Core
Public Member Functions | Static Public Member Functions | Private Attributes | List of all members
Cogs::Timer Class Reference

Old timer class. More...

#include <Timer.h>

Public Member Functions

void start ()
 
void stop ()
 
int64_t elapsedMicroseconds ()
 
int64_t elapsedMilliseconds ()
 
double elapsedSeconds ()
 
void setScale (int64_t s)
 
void resetScale ()
 
int64_t getScale () const
 
TimePerf scalePerfTime (TimePerf time)
 

Static Public Member Functions

static Timer startNew ()
 
static int64_t currentTimeMicroseconds ()
 
static int64_t currentTimeMilliseconds ()
 

Private Attributes

TimePerf startTime = {}
 
TimePerf stopTime = {}
 
int64_t scale = 1000
 
bool running = false
 

Detailed Description

Old timer class.

Definition at line 36 of file Timer.h.

Member Function Documentation

◆ currentTimeMicroseconds()

static int64_t Cogs::Timer::currentTimeMicroseconds ( )
inlinestatic

Definition at line 61 of file Timer.h.

◆ currentTimeMilliseconds()

static int64_t Cogs::Timer::currentTimeMilliseconds ( )
inlinestatic

Definition at line 62 of file Timer.h.

◆ elapsedMicroseconds()

int64_t Cogs::Timer::elapsedMicroseconds ( )
inline

Definition at line 57 of file Timer.h.

◆ elapsedMilliseconds()

int64_t Cogs::Timer::elapsedMilliseconds ( )
inline

Definition at line 58 of file Timer.h.

◆ elapsedSeconds()

double Cogs::Timer::elapsedSeconds ( )
inline

Definition at line 59 of file Timer.h.

◆ getScale()

int64_t Cogs::Timer::getScale ( ) const
inline

Definition at line 72 of file Timer.h.

◆ resetScale()

void Cogs::Timer::resetScale ( )
inline

Definition at line 71 of file Timer.h.

◆ scalePerfTime()

TimePerf Cogs::Timer::scalePerfTime ( TimePerf  time)
inline

Definition at line 73 of file Timer.h.

◆ setScale()

void Cogs::Timer::setScale ( int64_t  s)
inline

Definition at line 70 of file Timer.h.

◆ start()

void Cogs::Timer::start ( )
inline

Definition at line 46 of file Timer.h.

◆ startNew()

static Timer Cogs::Timer::startNew ( )
inlinestatic

Definition at line 39 of file Timer.h.

◆ stop()

void Cogs::Timer::stop ( )
inline

Definition at line 51 of file Timer.h.

Member Data Documentation

◆ running

bool Cogs::Timer::running = false
private

Definition at line 84 of file Timer.h.

◆ scale

int64_t Cogs::Timer::scale = 1000
private

Definition at line 82 of file Timer.h.

◆ startTime

TimePerf Cogs::Timer::startTime = {}
private

Definition at line 77 of file Timer.h.

◆ stopTime

TimePerf Cogs::Timer::stopTime = {}
private

Definition at line 78 of file Timer.h.


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