14 std::string c_case = from_json<std::string>(json);
19 if((c ==
'c') || (c ==
'k')) {
22 else if((c ==
'd') || (c ==
'f')) {
37 else if(value ==
CART) {
41 return to_json(
"COORD_DEFAULT", json);
47 std::string periodicity = from_json<std::string>(json);
49 if(periodicity ==
"PERIODIC") {
52 else if(periodicity ==
"LOCAL") {
55 else if(periodicity ==
"PERIODICITY_DEFAULT") {
60 ss <<
"Could not recognize PERIODICITY_TYPE from json: '" << periodicity <<
"'";
61 throw std::runtime_error(ss.str());
69 return to_json(
"PERIODIC", json);
71 else if(value ==
LOCAL) {
75 return to_json(
"PERIODICITY_DEFAULT", json);
81 std::string type = from_json<std::string>(json);
86 else if(type ==
"SCEL") {
91 ss <<
"Could not recognize CELL_TYPE from json: '" << type <<
"'";
92 throw std::runtime_error(ss.str());
void from_json(ClexDescription &desc, const jsonParser &json)
jsonParser & to_json(const ClexDescription &desc, jsonParser &json)