PhoenixSwarm  3.5.0
Library to ease communication between daemons
Loading...
Searching...
No Matches
StatDaemonManager.h
Go to the documentation of this file.
1/***************************************
2 Auteur : Thibaut Oprinsen
3 Mail : thibaut.oprinsen@lapp.in2p3.fr
4 Licence : CeCILL-C
5****************************************/
6
7#ifndef __STATDAEMONMANAGER_H__
8#define __STATDAEMONMANAGER_H__
9
10#include "Representation.h"
11#include "Daemon.h"
12#include "PUncastableBool.h"
13
14typedef std::map<PString, DaemonStat> MapDaemonStat;
15
17template<class _TBackend>
18class StatDaemonManager : public Daemon<_TBackend>{
19 public:
21 virtual ~StatDaemonManager();
22
23 const MapDaemonStat& getMapDaemonStat() const;
24 bool hasReceivedStats() const;
25 size_t getStatsCount() const;
26 PUncastableBool fillStatInfo(const DaemonStat & stat);
27 bool processEvent();
28 virtual void addCallMethod();
29 private:
33};
34
36
37#endif
std::map< PString, DaemonStat > MapDaemonStat
Statistics of a Daemon.
Daemon()
Default constructor of Daemon.
Definition Daemon_impl.h:15
MapDaemonStat p_mapDaemonStat
Statistics about all Daemon in the swarm.
virtual void addCallMethod()
Method from BaseDaemon to add call methods.
size_t getStatsCount() const
Get the count of stats received.
virtual ~StatDaemonManager()
Destructor of StatDaemonManager.
StatDaemonManager()
Constructor of StatDaemonManager.
bool hasReceivedStats() const
Check if stats have been received.
PUncastableBool fillStatInfo(const DaemonStat &stat)
Fill the StatInfo of the StatDaemonManager with the given DaemonStat.
void initializeStatDaemonManager()
Initialize the StatDaemonManager.
const MapDaemonStat & getMapDaemonStat() const
Get the map of DaemonStat.
bool processEvent()
Process event.