PhoenixSwarm  3.5.0
Library to ease communication between daemons
Loading...
Searching...
No Matches
DaemonStatAccumulator Class Reference

Accumulator of all events occurence on a Daemon (processing functions and communication latencies) to build swarm statistics over a time period. More...

#include <Representation.h>

Public Member Functions

 DaemonStatAccumulator ()
 Constructor of class DaemonStatAccumulator.
 
 DaemonStatAccumulator (const DaemonStatAccumulator &other)
 Copy Constructor of class DaemonStatAccumulator.
 
std::map< PString, std::map< PString, StatAccumulator > > & getMapStatCommunication ()
 Gets the mapStatCommunication of the DaemonStatAccumulator.
 
const std::map< PString, std::map< PString, StatAccumulator > > & getMapStatCommunication () const
 Gets the mapStatCommunication of the DaemonStatAccumulator.
 
std::map< PString, StatAccumulator > & getMapStatComputing ()
 Gets the mapStatComputing of the DaemonStatAccumulator.
 
const std::map< PString, StatAccumulator > & getMapStatComputing () const
 Gets the mapStatComputing of the DaemonStatAccumulator.
 
DaemonStatAccumulatoroperator= (const DaemonStatAccumulator &other)
 Operator = of class DaemonStatAccumulator.
 
template<typename Stream, DataStreamMode::DataStreamMode Mode>
bool readWriteStream (Stream &ds)
 Load the current DaemonStatAccumulator with a stream.
 
void setMapStatCommunication (const std::map< PString, std::map< PString, StatAccumulator > > &mapStatCommunication)
 Sets the mapStatCommunication of the DaemonStatAccumulator.
 
void setMapStatComputing (const std::map< PString, StatAccumulator > &mapStatComputing)
 Sets the mapStatComputing of the DaemonStatAccumulator.
 
virtual ~DaemonStatAccumulator ()
 Destructor of class DaemonStatAccumulator.
 

Protected Member Functions

void copyDaemonStatAccumulator (const DaemonStatAccumulator &other)
 Copy Function of class DaemonStatAccumulator.
 

Private Member Functions

void initialisationDaemonStatAccumulator ()
 Initialisation Function of class DaemonStatAccumulator.
 

Private Attributes

std::map< PString, std::map< PString, StatAccumulator > > p_mapStatCommunication
 Map of the communication statistics (key: destination daemon name, value: {key: data type, value: vector of associated stats })
 
std::map< PString, StatAccumulatorp_mapStatComputing
 Map of the computing statistics (key: stat name, value vector of stat)
 

Detailed Description

Accumulator of all events occurence on a Daemon (processing functions and communication latencies) to build swarm statistics over a time period.

Definition at line 537 of file Representation.h.

Constructor & Destructor Documentation

◆ DaemonStatAccumulator() [1/2]

DaemonStatAccumulator::DaemonStatAccumulator ( )

Constructor of class DaemonStatAccumulator.

Definition at line 1244 of file Representation.cpp.

1244 {
1246}
void initialisationDaemonStatAccumulator()
Initialisation Function of class DaemonStatAccumulator.

References initialisationDaemonStatAccumulator().

Referenced by copyDaemonStatAccumulator(), DaemonStatAccumulator(), and operator=().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ ~DaemonStatAccumulator()

DaemonStatAccumulator::~DaemonStatAccumulator ( )
virtual

Destructor of class DaemonStatAccumulator.

Definition at line 1249 of file Representation.cpp.

1249 {
1250
1251}

◆ DaemonStatAccumulator() [2/2]

DaemonStatAccumulator::DaemonStatAccumulator ( const DaemonStatAccumulator & other)

Copy Constructor of class DaemonStatAccumulator.

Parameters
other: DaemonStatAccumulator we want ot copy

Definition at line 1256 of file Representation.cpp.

1256 {
1258}
void copyDaemonStatAccumulator(const DaemonStatAccumulator &other)
Copy Function of class DaemonStatAccumulator.

References copyDaemonStatAccumulator(), and DaemonStatAccumulator().

+ Here is the call graph for this function:

Member Function Documentation

◆ copyDaemonStatAccumulator()

void DaemonStatAccumulator::copyDaemonStatAccumulator ( const DaemonStatAccumulator & other)
protected

Copy Function of class DaemonStatAccumulator.

Parameters
other: DaemonStatAccumulator we want ot copy

Definition at line 1314 of file Representation.cpp.

1314 {
1317}
std::map< PString, StatAccumulator > p_mapStatComputing
Map of the computing statistics (key: stat name, value vector of stat)
std::map< PString, std::map< PString, StatAccumulator > > p_mapStatCommunication
Map of the communication statistics (key: destination daemon name, value: {key: data type,...

References DaemonStatAccumulator(), p_mapStatCommunication, and p_mapStatComputing.

Referenced by DaemonStatAccumulator(), and operator=().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getMapStatCommunication() [1/2]

std::map< PString, std::map< PString, StatAccumulator > > & DaemonStatAccumulator::getMapStatCommunication ( )

Gets the mapStatCommunication of the DaemonStatAccumulator.

Returns
mapStatCommunication of the DaemonStatAccumulator

Definition at line 1307 of file Representation.cpp.

1307 {
1309}

References p_mapStatCommunication.

◆ getMapStatCommunication() [2/2]

const std::map< PString, std::map< PString, StatAccumulator > > & DaemonStatAccumulator::getMapStatCommunication ( ) const

Gets the mapStatCommunication of the DaemonStatAccumulator.

Returns
mapStatCommunication of the DaemonStatAccumulator

Definition at line 1300 of file Representation.cpp.

1300 {
1302}

References p_mapStatCommunication.

Referenced by CheckStream< DaemonStatAccumulator >::check_stream().

+ Here is the caller graph for this function:

◆ getMapStatComputing() [1/2]

std::map< PString, StatAccumulator > & DaemonStatAccumulator::getMapStatComputing ( )

Gets the mapStatComputing of the DaemonStatAccumulator.

Returns
mapStatComputing of the DaemonStatAccumulator

Definition at line 1293 of file Representation.cpp.

1293 {
1294 return p_mapStatComputing;
1295}

References p_mapStatComputing.

◆ getMapStatComputing() [2/2]

const std::map< PString, StatAccumulator > & DaemonStatAccumulator::getMapStatComputing ( ) const

Gets the mapStatComputing of the DaemonStatAccumulator.

Returns
mapStatComputing of the DaemonStatAccumulator

Definition at line 1286 of file Representation.cpp.

1286 {
1287 return p_mapStatComputing;
1288}

References p_mapStatComputing.

Referenced by CheckStream< DaemonStatAccumulator >::check_stream().

+ Here is the caller graph for this function:

◆ initialisationDaemonStatAccumulator()

void DaemonStatAccumulator::initialisationDaemonStatAccumulator ( )
private

Initialisation Function of class DaemonStatAccumulator.

Definition at line 1320 of file Representation.cpp.

1320 {
1321}

Referenced by DaemonStatAccumulator().

+ Here is the caller graph for this function:

◆ operator=()

DaemonStatAccumulator & DaemonStatAccumulator::operator= ( const DaemonStatAccumulator & other)

Operator = of class DaemonStatAccumulator.

Parameters
other: DaemonStatAccumulator we want ot copy
Returns
copied class DaemonStatAccumulator

Definition at line 1264 of file Representation.cpp.

1264 {
1266 return *this;
1267}

References copyDaemonStatAccumulator(), and DaemonStatAccumulator().

+ Here is the call graph for this function:

◆ readWriteStream()

template<typename Stream, DataStreamMode::DataStreamMode Mode>
bool DaemonStatAccumulator::readWriteStream ( Stream & ds)
inline

Load the current DaemonStatAccumulator with a stream.

Parameters
[out]ds: stream to be used
Returns
true on success, false otherwise

Definition at line 555 of file Representation.h.

555 {
556 bool b(true);
557 b &= DataStream<Stream, Mode, std::map<PString, StatAccumulator > >::data_stream(ds, p_mapStatComputing);
558 b &= DataStream<Stream, Mode, std::map<PString, std::map<PString, StatAccumulator > > >::data_stream(ds, p_mapStatCommunication);
559 return b;
560 }

References p_mapStatCommunication, and p_mapStatComputing.

Referenced by DataStream< Stream, Mode, DaemonStatAccumulator >::data_stream().

+ Here is the caller graph for this function:

◆ setMapStatCommunication()

void DaemonStatAccumulator::setMapStatCommunication ( const std::map< PString, std::map< PString, StatAccumulator > > & mapStatCommunication)

Sets the mapStatCommunication of the DaemonStatAccumulator.

Parameters
mapStatCommunication: mapStatCommunication of the DaemonStatAccumulator

Definition at line 1279 of file Representation.cpp.

1279 {
1280 p_mapStatCommunication = mapStatCommunication;
1281}

References p_mapStatCommunication.

◆ setMapStatComputing()

void DaemonStatAccumulator::setMapStatComputing ( const std::map< PString, StatAccumulator > & mapStatComputing)

Sets the mapStatComputing of the DaemonStatAccumulator.

Parameters
mapStatComputing: mapStatComputing of the DaemonStatAccumulator

Definition at line 1272 of file Representation.cpp.

1272 {
1273 p_mapStatComputing = mapStatComputing;
1274}

References p_mapStatComputing.

Member Data Documentation

◆ p_mapStatCommunication

std::map<PString, std::map<PString, StatAccumulator > > DaemonStatAccumulator::p_mapStatCommunication
private

Map of the communication statistics (key: destination daemon name, value: {key: data type, value: vector of associated stats })

Definition at line 569 of file Representation.h.

Referenced by copyDaemonStatAccumulator(), getMapStatCommunication(), getMapStatCommunication(), readWriteStream(), and setMapStatCommunication().

◆ p_mapStatComputing

std::map<PString, StatAccumulator > DaemonStatAccumulator::p_mapStatComputing
private

Map of the computing statistics (key: stat name, value vector of stat)

Definition at line 567 of file Representation.h.

Referenced by copyDaemonStatAccumulator(), getMapStatComputing(), getMapStatComputing(), readWriteStream(), and setMapStatComputing().


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