timer_clock Class Reference

#include <timer.h>


Detailed Description

Provide an interface for timing execution using clock().

Note:
Note that the time return by clock() is reset on some regular interval (sometimes 72 minutes) and this class does not yet account for this.

Definition at line 116 of file timer.h.


Public Member Functions

double time_since ()
 Number of seconds elapsed.
void time_since (int &d, int &h, int &m, int &s, double &f)
 Time elapsed in days, hours, minutes, seconds, and fractions of seconds.
void time_remaining (int n, int tot, int &d, int &h, int &m, int &s, double &f)
 Time remaining if n out of tot tasks have been completed.
std::string interval_to_string (int d, int h, int m, int s, double f=0.0)
 Convert a time interval to a string.

Protected Attributes

clock_t time
 Desc.

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

Documentation generated with Doxygen and provided under the GNU Free Documentation License. See License Information for details.

Project hosting provided by SourceForge.net Logo, O2scl Sourceforge Project Page