9 #include <atm/ModelRegister.h>
10 #include <atm/VRayleighModel.h>
11 #include <atm/VProfileModel.h>
12 #include <atm/VMieModel.h>
13 #include <atm/VFluorescenceModel.h>
14 #include <atm/VCherenkovModel.h>
15 #include <atm/VCloudModel.h>
17 #include <utl/AugerException.h>
18 #include <utl/ErrorLogger.h>
25 template<
typename ModelType>
28 ModelType*
const model)
30 fMap[modelName] = model;
34 template<
typename ModelType>
38 const typename InternalCollection::iterator it =
41 if (it == fMap.end()) {
43 err <<
"Could not retrieve model '" << modelName <<
'\'';
52 template<
typename ModelType>
57 const typename InternalCollection::const_iterator it =
60 if (it == fMap.end()) {
62 err <<
"Could not retrieve model '" << modelName <<
'\'';
71 template<
typename ModelType>
74 for (
typename InternalCollection::iterator it = fMap.begin();
75 it != fMap.end(); ++it)
void RegisterModel(const std::string &modelName, ModelType *const model)
Base class for exceptions trying to access non-existing components.
Registry of atmosphere models.
#define ERROR(message)
Macro for logging error messages.
ModelType & Get(const std::string &name)