Main Page Modules Class Hierarchy Compound List File List Compound Members File Members Related Pages Examples
Timer Class Reference
[GLT Misc]
Elapsed Time Object.
More...
#include <timer.h>
List of all members.
|
Public Methods |
| Timer () |
| Constructor.
|
| Timer (std::ostream &) |
| Constructor: Report elapsed time to output stream.
|
| ~Timer () |
| Destructor.
|
double | elapsed () const |
| Get the elapsed time (sec).
|
clock_t | clock () const |
| Get the number of clock ticks.
|
void | start () |
| Reset the timer.
|
Static Public Methods |
void | freeze () |
| Freeze all timers.
|
void | unFreeze () |
| Un-freeze all timers.
|
void | advance (const uint32 msec) |
| Advance all (frozen) timers.
|
Detailed Description
Elapsed Time Object.
- Author:
-
Nigel Stewart, RMIT (nigels.com@gmail.com)
- Note:
-
The precision of this object is limited to the ANSI C macro CLOCKS_PER_SEC
The timer object can be used for measuring elapsed time between events. The timer starts from the time the object is created, and is reset to zero when Timer::start() is called.
When an output stream is passed to the constructor, the elapsed time will be output when the timer is destroyed.
Definition at line 60 of file timer.h.
The documentation for this class was generated from the following files:
Generated on Tue Nov 5 11:11:49 2002 for GLT by
1.2.18