|
Hyperiso 1.0.3
Modular flavour-physics calculations, Wilson coefficients and statistical inference
|
Lightweight container for InterpretedParam mappings. More...
#include <MappingDatabase.h>
Public Member Functions | |
| MappingDatabase (const std::string &instanceName, const std::string &jsonFilePath, std::shared_ptr< IParamMappingSource > loader) | |
| Constructs a MappingDatabase and immediately loads mappings. | |
| std::unordered_map< std::string, InterpretedParam > | getParams () const |
| Returns the current parameter mapping. | |
Lightweight container for InterpretedParam mappings.
A MappingDatabase is essentially a cache of the parameter mapping file. It is responsible for:
It does not deal with higher-level concepts such as database instances or multiple mapping sets; that logic is handled by IMappingDatabaseAdapter implementations and factories.
Definition at line 32 of file MappingDatabase.h.
| MappingDatabase::MappingDatabase | ( | const std::string & | instanceName, |
| const std::string & | jsonFilePath, | ||
| std::shared_ptr< IParamMappingSource > | loader | ||
| ) |
Constructs a MappingDatabase and immediately loads mappings.
If loader is null, a default JSON-based loader (JsonParamMappingAdapter
| instanceName | Human-readable name of this mapping instance (used for logging only). |
| jsonFilePath | Path to the mapping file to be loaded. |
| loader | Source object responsible for reading and interpreting the mapping file. |
Definition at line 7 of file MappingDatabase.cpp.
| std::unordered_map< std::string, InterpretedParam > MappingDatabase::getParams | ( | ) | const |
Returns the current parameter mapping.
The returned map is a copy of the internal storage to keep the class logically immutable from the caller’s perspective.
Definition at line 33 of file MappingDatabase.cpp.