Public Member Functions

zeus::TStopWatch Class Reference

#include <StopWatch.hpp>

List of all members.

Public Member Functions

 TStopWatch (bool bStart=true)
void start ()
Float stop ()
void stopAndPrint (const TString &rEvent)
bool exceedTime (const Float &rfMaxTime)
Float getTime () const
Float getStoppedTime () const
void print (const TString &rEvent) const
void pause ()
void reset ()

Detailed Description

Class is used to measure the clock time between start end stop events


Constructor & Destructor Documentation

zeus::TStopWatch::TStopWatch ( bool  bStart = true ) [inline]

Creates the stop watch object


Member Function Documentation

bool zeus::TStopWatch::exceedTime ( const Float &  rfMaxTime ) [inline]

checks if the stop watch exceeds a certain time limit

Parameters:
rfMaxTime: Time limit
Return values:
true: time exceeded
false,:time not exceeded yet
Float zeus::TStopWatch::getStoppedTime (  ) const [inline]

returns the stopped time

Float zeus::TStopWatch::getTime (  ) const [inline]

returns the current time

void zeus::TStopWatch::pause (  ) [inline]

Pauses the stop watch

void zeus::TStopWatch::print ( const TString rEvent ) const [inline]

returns the stopped time

void zeus::TStopWatch::reset (  ) [inline]

resets the watch. This will stop the watch and resets the paused time

void zeus::TStopWatch::start (  ) [inline]

starts the watch

Float zeus::TStopWatch::stop (  ) [inline]

stops the watch

void zeus::TStopWatch::stopAndPrint ( const TString rEvent ) [inline]

stops the watch and prints the message to the stdout


The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines


Written by Benjamin Hadorn http://www.xatlantis.ch.
Last change made on Sun Jan 22 2012 15:28:40