40 #ifndef __model_parameters_hpp__ 41 #define __model_parameters_hpp__ 59 void assert_contains(std::string)
const;
73 double getValue(std::string
const & inkey)
const;
76 const std::map<std::string, double>& getValues()
const;
79 std::map<std::string, double>::const_iterator begin()
const;
82 std::map<std::string, double>::const_iterator end()
const;
85 int getNumberOfPars()
const;
88 const double & operator[](std::string
const & inkey)
const;
91 const double & at(std::string
const & inkey)
const;
94 void setValue(std::string
const &inkey,
double const&value);
97 void setValues(std::map<std::string,double>
const ¶ms_map,
bool missing_is_error =
true);
100 void setValues(
ModelParameters const& donor,
bool missing_is_error =
true);
103 std::vector<std::string> getKeys()
const;
111 strm <<
"ModelParameters: Printing: "<<std::endl;
112 for (std::map<std::string,double>::const_iterator it=me.
_values.begin();it!=me.
_values.end();it++)
114 strm <<
"parameter: " << it->first <<
" value: "<<it->second ;
120 void _definePar(
const std::string &newkey);
123 void _definePars(
const std::vector<std::string> &v);
126 void _definePars(
const char** array);
129 std::string getModelName()
const;
130 std::string getOutputName()
const;
131 void setModelName (
const std::string&);
132 void setOutputName(
const std::string&);
149 #endif //ifdef __model_parameters_hpp__ std::string outputname
Output name (string used for labelling in output, related to the model_functor which produced these p...
void print(MixMatrix A)
Helper function to print a matrix.
std::map< std::string, double > _values
Internal map representation of parameters and their values.
std::map< std::string, double > parameterMap
std::string modelname
Name of the model; intended mainly for more helpful error messages.
friend std::ostream & operator<<(std::ostream &strm, const ModelParameters &me)
Dump parameter names and values to stream (again for debugging only I think)
Helper macro for controlling symbol visibility in shared libraries.
TODO: see if we can use this one: