27 #ifndef BASICSIMULATION_H
28 #define BASICSIMULATION_H
50 void build_component_list ( );
95 _allParams.push_back(paramset);
100 ParamSet* get_paramset (
string& name);
102 void build_allParams ( );
123 bool set_parameters (map< string,string >& simparams,
bool silent);
129 bool param_consistency_check ( );
131 void build_records (map<
string, vector<string> >& initParams);
153 string setFilename (
string& fstring,
unsigned int sim, vector<string>& args, vector<unsigned int>& arg_no, vector<bool>& is_linked, vector<string>& names,
bool check_arg_no);
154 string stripFormatString (
string& str,
unsigned int& index);
155 string setArgString (
string& fmt,
string& arg,
unsigned int arg_pos);
156 string lowercase (
string& input);
176 bool build_currentParams (map< string,string >& simparams);
180 map< trait_t,TraitPrototype* >& build_currentTraits ( );
183 void build_LifeCycle ( );
214 age_t getFirstRequiredAgeInLifeCycle ( );
224 typedef map< int, LifeCycleEvent* >::const_iterator
LCE_ITER;
225 typedef map< trait_t, TraitPrototype* >::const_iterator
TRAIT_ITER;
Class to manage the simulation components and prototypes.
Definition: basicsimulation.h:44
list< LifeCycleEvent * > _LCE_Templates
List of all the life-cycle events of the simulation, a subset of _components list.
Definition: basicsimulation.h:73
list< TraitPrototype * > _TTrait_Templates
List of all trait prototypes of the simulation, a subset of _components list.
Definition: basicsimulation.h:71
void add_component(SimComponent *cmpt)
Push a component at the back of the component list.
Definition: basicsimulation.h:52
void add_LCE(LifeCycleEvent *event)
Add a life cycle event to the template and component lists.
Definition: basicsimulation.h:56
~ComponentManager()
Definition: basicsimulation.h:48
list< SimComponent * > _components
List of all the simulation components.
Definition: basicsimulation.h:69
void add_trait(TraitPrototype *trait)
Add a trait prototype to the template and component lists.
Definition: basicsimulation.h:54
ComponentManager()
Definition: basicsimulation.h:47
Base class of the Life Cycle Events, declares the LCE interface.
Definition: lifecycleevent.h:71
Class to manage the sets of parameters of the simulation components.
Definition: basicsimulation.h:87
~ParamManager()
Definition: basicsimulation.h:91
list< map< string, string > > _simRecords
Sets of parameters of all the simulations to perform.
Definition: basicsimulation.h:147
int get_nbSims()
Accessor to the size of the simulations parameter list, i.e.
Definition: basicsimulation.h:137
list< ParamSet * > _allParams
A list of all the parameter sets of all the simulation components loaded in the _component list of th...
Definition: basicsimulation.h:141
map< unsigned int, list< pair< string, string > > > _temporalParams
Lists of parameters to be updated during a simulation indexed by generation update time.
Definition: basicsimulation.h:145
list< ParamSet * > & get_allParams()
Accessor of the whole list of the parameter sets.
Definition: basicsimulation.h:106
ParamSet _paramSet
The ParamSet param set of the simulation.
Definition: basicsimulation.h:149
map< string, string > _inputParams
A map of the parameters and their arguments of the current (running) simulation.
Definition: basicsimulation.h:143
map< string, string > & get_firstRecord()
Accessor to the first element in the simulations parameter list.
Definition: basicsimulation.h:135
void add_paramset(ParamSet *paramset)
Adds a ParamSet to the list of the parameter sets of the simulation.
Definition: basicsimulation.h:93
list< map< string, string > > & get_simRecords()
Accessor to the simulations parameter list.
Definition: basicsimulation.h:133
Parameters container, implemented in each SimComponent.
Definition: param.h:214
Provides methods to build the user's selected set of life cycle events and traits from the parameters...
Definition: basicsimulation.h:166
map< trait_t, TraitPrototype * > _currentTraits
List of the selected trait prototypes from the user defined input parameters.
Definition: basicsimulation.h:220
list< ParamSet * > _currentParams
List of the selected simulation components from the user defined input parameters.
Definition: basicsimulation.h:218
map< int, LifeCycleEvent * >::const_iterator LCE_ITER
Definition: basicsimulation.h:224
list< ParamSet * > & get_currentParams()
Accessor to the list of the selected parameter sets.
Definition: basicsimulation.h:212
map< trait_t, TraitPrototype * >::const_iterator TRAIT_ITER
Definition: basicsimulation.h:225
SimBuilder()
Definition: basicsimulation.h:168
map< int, LifeCycleEvent * > _LifeCycle
List of the selected life cycle events from the user defined input parameters.
Definition: basicsimulation.h:222
Interface to all basic components of a simulation (traits, life cycle events, pop,...
Definition: simcomponent.h:43
TTrait setter.
Definition: ttrait.h:129
std::string trait_t
Trait types.
Definition: types.h:61
unsigned int age_t
Age class flags.
Definition: types.h:44