Nemo  2.3.46
updaterservices.h
Go to the documentation of this file.
1 
30 #ifndef UPDATERSERVICES_H
31 #define UPDATERSERVICES_H
32 
33 #include <map>
34 #include <list>
35 #include "service.h"
36 #include "param.h"
37 
38 using namespace std;
39 
40 class SimComponent;
64 class UpdaterServices : public Service {
65 
66 private:
67 
68  map< unsigned int, list< Param* > > _paramUpdater;
69  map< unsigned int, list< ParamUpdaterBase* > > _componentUpdater;
70  list< ParamUpdaterBase* > _updaters;
71 
72 public:
73 
75  virtual ~UpdaterServices () {reset();}
76 
77  virtual bool init ();
78  virtual void notify () {}
80  virtual void notify (unsigned int generation);
82  virtual void load ( SimComponent* sc );
84  virtual void attach ( Handler* H );
86  virtual void reset();
88  void update_params (unsigned int generation);
90  void update_components (unsigned int generation);
92  bool hasTemporals () {return !_paramUpdater.empty();}
93 };
94 
95 #endif
Class to update the simulation components' state during a simulation.
Definition: updaterservices.h:64
list< ParamUpdaterBase * > _updaters
Definition: updaterservices.h:70
virtual ~UpdaterServices()
Definition: updaterservices.h:75
map< unsigned int, list< Param * > > _paramUpdater
Definition: updaterservices.h:68
virtual void notify()
Definition: updaterservices.h:78
UpdaterServices()
Definition: updaterservices.h:74
bool hasTemporals()
Checks if any updater has been uploaded.
Definition: updaterservices.h:92
Interface to all basic components of a simulation (traits, life cycle events, pop, etc. ).
Definition: simcomponent.h:45
Service handler (an observer).
Definition: handler.h:36
map< unsigned int, list< ParamUpdaterBase * > > _componentUpdater
Definition: updaterservices.h:69
Interface for the simulation services (files and stats).
Definition: service.h:43

Generated for Nemo v2.3.0 by  doxygen 1.8.8 --
Catalogued on GSR