# Home    # nevrax.com   
Nevrax
Nevrax.org
#News
#Mailing-list
#Documentation
#CVS
#Bugs
#License
Docs
 
Documentation  
Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages   Search  

NLMISC::CSimpleClock Class Reference

A simple clock to measure ticks. More...

#include <hierarchical_timer.h>

List of all members.

Public Methods

 CSimpleClock ()
void start ()
void stop ()
uint64 getNumTicks () const

Static Public Methods

void init ()
uint64 getStartStopNumTicks ()
 Get the number of ticks needed to perform start(). More...


Private Attributes

uint64 _StartTick
uint64 _NumTicks

Static Private Attributes

bool _InitDone = false
uint64 _StartStopNumTicks = 0


Detailed Description

A simple clock to measure ticks.

Warning:
On intel platform, processor cycles are counted, on other platforms, CTime::getPerformanceTime is used instead.
See also:
CStopWatch
Author:
Nicolas Vizerie , Nevrax France
Date:
2002

Definition at line 114 of file hierarchical_timer.h.


Constructor & Destructor Documentation

NLMISC::CSimpleClock::CSimpleClock   [inline]
 

Definition at line 117 of file hierarchical_timer.h.

References _NumTicks.

Referenced by init.


Member Function Documentation

uint64 NLMISC::CSimpleClock::getNumTicks   const [inline]
 

Definition at line 151 of file hierarchical_timer.h.

References _NumTicks, and nlassert.

uint64 NLMISC::CSimpleClock::getStartStopNumTicks   [inline, static]
 

Get the number of ticks needed to perform start().

Should have called init() before calling this.

Definition at line 164 of file hierarchical_timer.h.

References _StartStopNumTicks.

void NLMISC::CSimpleClock::init   [static]
 

Definition at line 64 of file hierarchical_timer.cpp.

References _InitDone, _StartStopNumTicks, CSimpleClock, and NLAISCRIPT::l.

void NLMISC::CSimpleClock::start   [inline]
 

Definition at line 124 of file hierarchical_timer.h.

References _StartTick, and nlassert.

void NLMISC::CSimpleClock::stop void    [inline]
 

Definition at line 137 of file hierarchical_timer.h.

References _NumTicks, _StartTick, and nlassert.


Member Data Documentation

bool NLMISC::CSimpleClock::_InitDone = false [static, private]
 

Definition at line 42 of file hierarchical_timer.cpp.

Referenced by init.

uint64 NLMISC::CSimpleClock::_NumTicks [private]
 

Definition at line 170 of file hierarchical_timer.h.

Referenced by CSimpleClock, getNumTicks, and stop.

uint64 NLMISC::CSimpleClock::_StartStopNumTicks = 0 [static, private]
 

Definition at line 43 of file hierarchical_timer.cpp.

Referenced by getStartStopNumTicks, and init.

uint64 NLMISC::CSimpleClock::_StartTick [private]
 

Definition at line 169 of file hierarchical_timer.h.

Referenced by start, and stop.


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