Skip to content
Snippets Groups Projects
Commit 39340f82 authored by Carsten Gräser's avatar Carsten Gräser
Browse files

Added possibility to create a stopped timer

[[Imported from SVN: r5848]]
parent 873ad6bb
No related branches found
No related tags found
No related merge requests found
......@@ -46,15 +46,17 @@ namespace Dune {
{
public:
//! A new timer, reset and start immediately.
Timer () throw(TimerError)
/** \brief A new timer, create and reset
*
* \param startImmediately If true (default) the timer starts counting immediately
*/
Timer (bool startImmediately=true) throw(TimerError)
{
isRunning_ = true;
isRunning_ = startImmediately;
reset();
}
//! Reset timer and restart if running.
//! Reset timer while keeping the running/stoped state
void reset() throw (TimerError)
{
sumElapsed_ = 0.0;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment