Main Page   Class Hierarchy   Alphabetical List   Compound List   Compound Members  

util::Timer Class Reference

#include <Timer.h>

Inheritance diagram for util::Timer:

util::Object List of all members.

Detailed Description

Timer uses the system's real-time clock to perform nanosecond-resolution timing.

In practical use, the maximum resolution is never achieved, but accurate timings are still possible.


Public Methods

void start ()
 Start the timer.

double getTime ()
 Get the time elapsed from the last start() call.

void getTime (int &seconds, long &nanoseconds)
 Get the time elapsed from the last start() call.


Member Function Documentation

void util::Timer::getTime int &    seconds,
long &    nanoseconds
 

Get the time elapsed from the last start() call.

Parameters:
seconds  where to store the number of seconds elapsed
nanoseconds  where to store the number of nanoseconds elapsed

double util::Timer::getTime  
 

Get the time elapsed from the last start() call.

Time is measured in seconds.

void util::Timer::start void    [inline]
 

Start the timer.

If the timer is already started, the previous start time is lost.


The documentation for this class was generated from the following files:
Documentation generated on 11.09.2003 with Doxygen.
The documentation is copyrighted material.
Copyright © Topi Mäenpää 2003. All rights reserved.