ANNA Suite  2020b
Multipurpose development suite for Telco applications
Public Member Functions | List of all members
anna::statistics::Meter Class Reference

Processing time control. More...

#include <Meter.hpp>

Public Member Functions

 Meter (const std::string &name)
 
 ~Meter ()
 
void setControlPoint (void)
 
void reset (void)
 
Millisecond process (void)
 
const Meteroperator= (const Meter &meter)
 
double getAccumulatorValue (const Operation::Type &operation) const
 
std::string asString (const int &numberOfDecimals=2) const
 
anna::xml::NodeasXML (anna::xml::Node *parent, const int &numberOfDecimals=2) const
 

Detailed Description

Processing time control.

Accumulated data information for statistic sample oriented to processing time. It manage a single concept, with integer nature sample and unit 'milliseconds'.

Constructor & Destructor Documentation

◆ Meter()

anna::statistics::Meter::Meter ( const std::string &  name)

Constructor.

◆ ~Meter()

anna::statistics::Meter::~Meter ( )

Destructor.

Member Function Documentation

◆ asString()

std::string anna::statistics::Meter::asString ( const int &  numberOfDecimals = 2) const

Class string representation

Parameters
numberOfDecimalsNumber of float decimals at representation string. Default is 2.
Returns
String with class content

◆ asXML()

anna::xml::Node* anna::statistics::Meter::asXML ( anna::xml::Node parent,
const int &  numberOfDecimals = 2 
) const

Class XML representation

Parameters
numberOfDecimalsNumber of float decimals at XML representation. Default is 2.
Returns
XML with class content

◆ getAccumulatorValue()

double anna::statistics::Meter::getAccumulatorValue ( const Operation::Type operation) const
inline

Gets accumulator information in order to extract statistics indicators Gets accumulator value information (statistics indicators)

Parameters
operationSolicited operation
Returns
Value for solicited operation
104 { return (a_accumulator.getValue(a_single_accumulator_concept_id, operation)); }
double getValue(const int &conceptId, const Operation::Type &operation) const noexcept(false)

◆ operator=()

const Meter& anna::statistics::Meter::operator= ( const Meter meter)

Copy operator

Parameters
MeterClass instance source of data
Returns
Returns copied reference

◆ process()

Millisecond anna::statistics::Meter::process ( void  )
inline

Process new value for the sample: milliseconds time since last control point

Returns
Returns processed delay
76 { a_accumulator.process(a_single_accumulator_concept_id, a_meter.getDelay()); return (a_meter.getDelay()); }
Millisecond getDelay() const
Definition: Meter.hpp:98
void process(const int &conceptId, const double &value) noexcept(false)

◆ reset()

void anna::statistics::Meter::reset ( void  )
inline

Reset sample

68 { a_accumulator.reset(); }

◆ setControlPoint()

void anna::statistics::Meter::setControlPoint ( void  )
inline

Sets the time control point for processing measure

62 { a_meter.setControlPoint(); }
Millisecond setControlPoint()
Definition: Meter.hpp:62

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