31 std::vector<std::variant<DensityBasedSurfaceSite, MoleBasedSurfaceSite>>
34 auto const surface_site_unit =
36 config->getConfigAttribute<std::string>(
"site_unit",
"mole");
38 if (surface_site_unit ==
"density")
40 for (
auto const& site_config :
42 config->getConfigSubtreeList(
"site"))
45 auto name = site_config.getConfigParameter<std::string>(
"name");
47 auto const site_density =
49 site_config.getConfigParameter<
double>(
"site_density");
51 auto const specific_surface_area =
53 site_config.getConfigParameter<
double>(
"specific_surface_area");
57 site_config.getConfigParameter<
double>(
"mass");
60 std::move(name), site_density, specific_surface_area, mass));
66 if (surface_site_unit ==
"mole")
68 for (
auto const& site_config :
70 config->getConfigSubtreeList(
"site"))
73 auto name = site_config.getConfigParameter<std::string>(
"name");
84 OGS_FATAL(
"Surface site unit should be either of 'density' or 'mole'.");