Checks if the SMASH version is compatible with the version of the configuration file.
299 const std::string smash_version =
"1.5";
300 const std::set<std::string> compatible_config_versions = {
"1.5"};
304 if (compatible_config_versions.find(config_version) ==
305 compatible_config_versions.end()) {
306 std::stringstream err;
307 err <<
"The version of the configuration file (" << config_version
308 <<
") is not compatible with the SMASH version (" << smash_version
309 <<
").\nThe following config versions are supported:\n";
310 for (
auto it : compatible_config_versions) {
313 err <<
"\nPlease consider updating your config or using a compatible SMASH" 315 throw std::runtime_error(err.str());
Value read(std::initializer_list< const char *> keys) const
Additional interface for SMASH to read configuration values without removing them.
Configuration configuration(std::string overrides={})
Return a configuration object filled with data from src/config.yaml.