AGX Dynamics  2.37.3.2
agx::Statistics::Data< T > Class Template Reference

Statistics data storage class. More...

#include <Statistics.h>

+ Inheritance diagram for agx::Statistics::Data< T >:

Public Member Functions

 Data (const char *name)
 
T & accumulatedValue ()
 Returns the accumulated value of this statistics data handle. More...
 
const T & accumulatedValue () const
 
virtual void clear (bool clearAccumulated=true) override
 Sets the current and accumulated values to zero, or the equivalent for complex types. More...
 
agx::UInt getNumAccumulated () const
 
void report (const T &value)
 
virtual agxData::Value * toValue () const override
 
T & value ()
 Returns the current value of this statistics data handle. More...
 
const T & value () const
 

Protected Member Functions

virtual ~Data ()
 
virtual const void * accumulatedPtr () const override
 
virtual const void * valuePtr () const override
 

Detailed Description

template<typename T>
class agx::Statistics::Data< T >

Statistics data storage class.

Records both the most recently reported values and an accumulation of all reportings.

Definition at line 105 of file Statistics.h.

Constructor & Destructor Documentation

◆ Data()

template<typename T>
agx::Statistics::Data< T >::Data ( const char *  name)

◆ ~Data()

template<typename T>
virtual agx::Statistics::Data< T >::~Data ( )
protectedvirtual

Member Function Documentation

◆ accumulatedPtr()

template<typename T>
virtual const void* agx::Statistics::Data< T >::accumulatedPtr ( ) const
overrideprotectedvirtual

◆ accumulatedValue() [1/2]

template<typename T>
T& agx::Statistics::Data< T >::accumulatedValue ( )

Returns the accumulated value of this statistics data handle.

This is the sum of all reported values since the last reset.

◆ accumulatedValue() [2/2]

template<typename T>
const T& agx::Statistics::Data< T >::accumulatedValue ( ) const

◆ clear()

template<typename T>
virtual void agx::Statistics::Data< T >::clear ( bool  clearAccumulated = true)
overridevirtual

Sets the current and accumulated values to zero, or the equivalent for complex types.

Uses default constructor.

◆ getNumAccumulated()

template<typename T>
agx::UInt agx::Statistics::Data< T >::getNumAccumulated ( ) const

◆ report()

template<typename T>
void agx::Statistics::Data< T >::report ( const T &  value)

◆ toValue()

template<typename T>
virtual agxData::Value* agx::Statistics::Data< T >::toValue ( ) const
overridevirtual

◆ value() [1/2]

template<typename T>
T& agx::Statistics::Data< T >::value ( )

Returns the current value of this statistics data handle.

In the absence of 'reportAdditionalTiming(*)' calls this is the value passed to the last call to 'report(*)'.

◆ value() [2/2]

template<typename T>
const T& agx::Statistics::Data< T >::value ( ) const

◆ valuePtr()

template<typename T>
virtual const void* agx::Statistics::Data< T >::valuePtr ( ) const
overrideprotectedvirtual

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