Main Page   Groups   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Concepts

itk::ResourceProbe< ValueType, MeanType > Class Template Reference

#include <itkResourceProbe.h>

Inheritance diagram for itk::ResourceProbe< ValueType, MeanType >:

Inheritance graph
[legend]
Collaboration diagram for itk::ResourceProbe< ValueType, MeanType >:

Collaboration graph
[legend]

List of all members.


Detailed Description

template<class ValueType, class MeanType>
class itk::ResourceProbe< ValueType, MeanType >

Class for computing the change of a value between two points in the code.

This class is the base class of all the probes (time, memory, etc.) between the execution of two pieces of code. It can be started and stopped in order to evaluate the execution over multiple passes.

See also:
TimeResourceProbe, MemoryResourceProbe

Definition at line 39 of file itkResourceProbe.h.


Public Types

typedef unsigned long CountType

Public Member Functions

virtual ValueType GetInstantValue (void) const =0
MeanType GetMean (void) const
CountType GetNumberOfStarts (void) const
CountType GetNumberOfStops (void) const
ValueType GetTotal (void) const
std::string GetType (void) const
std::string GetUnit (void) const
 ResourceProbe (const std::string &type, const std::string &unit)
void Start (void)
void Stop (void)
virtual ~ResourceProbe ()

Member Typedef Documentation

template<class ValueType, class MeanType>
typedef unsigned long itk::ResourceProbe< ValueType, MeanType >::CountType

Type for counting how many times the probe has been started and stopped.

Reimplemented in itk::TimeProbe.

Definition at line 45 of file itkResourceProbe.h.


Constructor & Destructor Documentation

template<class ValueType, class MeanType>
itk::ResourceProbe< ValueType, MeanType >::ResourceProbe ( const std::string &  type,
const std::string &  unit 
)

Constructor

template<class ValueType, class MeanType>
virtual itk::ResourceProbe< ValueType, MeanType >::~ResourceProbe (  )  [virtual]

Destructor


Member Function Documentation

template<class ValueType, class MeanType>
virtual ValueType itk::ResourceProbe< ValueType, MeanType >::GetInstantValue ( void   )  const [pure virtual]

Returns the instant value of the probed system.

Implemented in itk::MemoryProbe, and itk::TimeProbe.

template<class ValueType, class MeanType>
MeanType itk::ResourceProbe< ValueType, MeanType >::GetMean ( void   )  const

Returns the average value changes between the starts and stops of the probe. Stop() has to be called at least once, returns 0 otherwise.

template<class ValueType, class MeanType>
CountType itk::ResourceProbe< ValueType, MeanType >::GetNumberOfStarts ( void   )  const

Returns the number of times that the probe has been started

template<class ValueType, class MeanType>
CountType itk::ResourceProbe< ValueType, MeanType >::GetNumberOfStops ( void   )  const

Returns the number of times that the probe has been stopped

template<class ValueType, class MeanType>
ValueType itk::ResourceProbe< ValueType, MeanType >::GetTotal ( void   )  const

Returns the accumulated value changes between the starts and stops of the probe

template<class ValueType, class MeanType>
std::string itk::ResourceProbe< ValueType, MeanType >::GetType ( void   )  const

Returns the type probed value

template<class ValueType, class MeanType>
std::string itk::ResourceProbe< ValueType, MeanType >::GetUnit ( void   )  const

Returns the unit probed value

template<class ValueType, class MeanType>
void itk::ResourceProbe< ValueType, MeanType >::Start ( void   ) 

Start counting the change of value

Examples:
Testing/Code/Common/itkVectorImageTest.cxx.

Referenced by itk::XMLFilterWatcher::StartFilter().

template<class ValueType, class MeanType>
void itk::ResourceProbe< ValueType, MeanType >::Stop ( void   ) 

Stop counting the change of value

Examples:
Testing/Code/Common/itkVectorImageTest.cxx.

Referenced by itk::XMLFilterWatcher::EndFilter().


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

Generated at Thu May 28 17:06:57 2009 for ITK by doxygen 1.5.5 written by Dimitri van Heesch, © 1997-2000