#include <wallclocktimer.h>
Public Member Functions | |
Construction / destruction | |
WallclockTimer () | |
default constructor More... | |
WallclockTimer (const WallclockTimer &old) | |
copy constructor More... | |
WallclockTimer & | operator= (const WallclockTimer &old) |
assignment operator More... | |
virtual | ~WallclockTimer () |
Control | |
virtual void | reset () |
initialize timer, set timing accounts to zero. More... | |
virtual void | start () |
start timer, resume accounting user, system and real time. More... | |
virtual Real | stop () |
stop timer, return accounted user time. More... | |
virtual TYPE | type () |
return type of timer More... | |
Access | |
virtual Real | time () const |
virtual Real | lastTime () const |
Public Member Functions inherited from Timer | |
Timer () | |
default constructor More... | |
Timer (const Timer &old) | |
copy constructor More... | |
Timer & | operator= (const Timer &old) |
assignment operator More... | |
virtual | ~Timer () |
void | getLastTimes (Real *userTime, Real *systemTime, Real *realTime) const |
return accounted time. get accounted user, system, or real time when ticks were updated last More... | |
Real | realTimeLast () const |
return accounted real time without rechecking the clock More... | |
Private Member Functions | |
Internal helpers | |
Real | wall2sec (long s, long us) const |
convert wallclock time to secounds. More... | |
Private Attributes | |
Data | |
long | sec |
seconds More... | |
long | usec |
microseconds More... | |
Real | lasttime |
Additional Inherited Members | |
Public Types inherited from Timer | |
enum | TYPE { OFF = 0, USER_TIME = 1, WALLCLOCK_TIME = 2 } |
types of timers More... | |
Protected Types inherited from Timer | |
enum | { RESET, STOPPED, RUNNING } |
status of the timer More... | |
Protected Attributes inherited from Timer | |
enum soplex::Timer::{ RESET, STOPPED, RUNNING } | status |
status of the timer More... | |
Definition at line 29 of file wallclocktimer.h.
WallclockTimer | ( | ) |
default constructor
Definition at line 59 of file wallclocktimer.h.
WallclockTimer | ( | const WallclockTimer & | old | ) |
copy constructor
Definition at line 63 of file wallclocktimer.h.
|
virtual |
Definition at line 75 of file wallclocktimer.h.
|
virtual |
Implements Timer.
Definition at line 129 of file wallclocktimer.cpp.
References WallclockTimer::lasttime.
Referenced by WallclockTimer::type().
WallclockTimer& operator= | ( | const WallclockTimer & | old | ) |
assignment operator
Definition at line 67 of file wallclocktimer.h.
References WallclockTimer::lasttime, WallclockTimer::sec, and WallclockTimer::usec.
|
virtual |
initialize timer, set timing accounts to zero.
Implements Timer.
Definition at line 83 of file wallclocktimer.h.
References Timer::RESET, WallclockTimer::start(), Timer::status, and WallclockTimer::stop().
|
virtual |
start timer, resume accounting user, system and real time.
Implements Timer.
Definition at line 33 of file wallclocktimer.cpp.
References WallclockTimer::lasttime, Timer::RUNNING, WallclockTimer::sec, Timer::status, WallclockTimer::time(), and WallclockTimer::usec.
Referenced by WallclockTimer::reset().
|
virtual |
stop timer, return accounted user time.
Implements Timer.
Definition at line 65 of file wallclocktimer.cpp.
References WallclockTimer::lasttime, Timer::RUNNING, WallclockTimer::sec, Timer::status, Timer::STOPPED, WallclockTimer::time(), WallclockTimer::usec, and WallclockTimer::wall2sec().
Referenced by WallclockTimer::reset().
|
virtual |
Implements Timer.
Definition at line 100 of file wallclocktimer.cpp.
References WallclockTimer::lasttime, Timer::RUNNING, WallclockTimer::sec, Timer::status, WallclockTimer::usec, and WallclockTimer::wall2sec().
Referenced by WallclockTimer::start(), WallclockTimer::stop(), and WallclockTimer::type().
|
virtual |
return type of timer
Implements Timer.
Definition at line 97 of file wallclocktimer.h.
References WallclockTimer::lastTime(), WallclockTimer::time(), and Timer::WALLCLOCK_TIME.
|
private |
convert wallclock time to secounds.
Definition at line 46 of file wallclocktimer.h.
Referenced by WallclockTimer::stop(), and WallclockTimer::time().
|
mutableprivate |
Definition at line 39 of file wallclocktimer.h.
Referenced by WallclockTimer::lastTime(), WallclockTimer::operator=(), WallclockTimer::start(), WallclockTimer::stop(), and WallclockTimer::time().
|
mutableprivate |
seconds
Definition at line 36 of file wallclocktimer.h.
Referenced by WallclockTimer::operator=(), WallclockTimer::start(), WallclockTimer::stop(), and WallclockTimer::time().
|
mutableprivate |
microseconds
Definition at line 37 of file wallclocktimer.h.
Referenced by WallclockTimer::operator=(), WallclockTimer::start(), WallclockTimer::stop(), and WallclockTimer::time().