58 std::vector<ProcessVariable>
const& variables,
60 std::initializer_list<std::string>
63 std::vector<std::reference_wrapper<ProcessVariable>> vars;
64 vars.reserve(variables.size());
66 if (variables.size() > tags.size())
67 DBUG(
"Found multiple process variables with a same tag.");
69 for (
auto const& tag : tags)
72 vars.insert(vars.end(), vars_per_tag.begin(), vars_per_tag.end());
79 std::vector<ProcessVariable>
const& variables,
86 if (var_names.empty())
92 OGS_FATAL(
"No entity is found with config tag <{:s}>.", tag);
95 std::vector<std::reference_wrapper<ProcessVariable>> vars;
96 std::vector<std::string> cached_var_names;
98 for (std::string
const& var_name : var_names)
100 vars.emplace_back(findVariableByName(variables, var_name, tag));
101 cached_var_names.push_back(var_name);
107 if (cached_var_names.size() != var_names.size())
109 OGS_FATAL(
"Found duplicates with config tag <{:s}>.", tag);