void colvar::cvc::parse_group (std::string const &conf, char const *group_key, cvm::atom_group &group, bool optional) { if (key_lookup (conf, group_key)) { group.parse (conf, group_key); } else { if (! optional) { cvm::fatal_error ("Error: definition for atom group \""+ std::string (group_key)+"\" not found.\n"); } } }
void colvar::cvc::parse_group (std::string const &conf, char const *group_key, cvm::atom_group &group, bool optional) { if (key_lookup (conf, group_key)) { if (group.parse (conf, group_key) != COLVARS_OK) { cvm::error ("Error parsing definition for atom group \""+ std::string (group_key)+"\".\n"); return; } } else { if (! optional) { cvm::error ("Error: definition for atom group \""+ std::string (group_key)+"\" not found.\n"); return; } } }