Heidelberg Educational Numerics Library Version 0.27 (from 15 March 2021)
Public Member Functions | List of all members
hdnum::Timer Class Reference

A simple stop watch. More...

#include <timer.hh>

Public Member Functions

 Timer ()
 A new timer, start immediately.
 
void reset ()
 Reset timer.
 
double elapsed () const
 Get elapsed user-time in seconds.
 

Detailed Description

A simple stop watch.

This class reports the elapsed user-time, i.e. time spent computing, after the last call to Timer::reset(). The results are seconds and fractional seconds. Note that the resolution of the timing depends on your OS kernel which should be somewhere in the milisecond range.

The class is basically a wrapper for the libc-function getrusage()

Taken from the DUNE project www.dune-project.org


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