Changeset 2203 for XIOS/dev/dev_ym/XIOS_COUPLING/src/node/domain.cpp
- Timestamp:
- 08/20/21 14:38:23 (3 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
XIOS/dev/dev_ym/XIOS_COUPLING/src/node/domain.cpp
r2196 r2203 26 26 #include "transformation_path.hpp" 27 27 28 29 30 31 28 #include <algorithm> 29 #include <regex> 30 32 31 33 32 namespace xios { … … 79 78 } 80 79 CATCH 80 81 CDomain* CDomain::get(const string& id) 82 { 83 const regex r("::"); 84 smatch m; 85 if (regex_search(id, m, r)) 86 { 87 if (m.size()!=1) ERROR("CDomain* CDomain::get(string& id)", <<" id = "<<id<< " -> bad format id, separator :: append more than one time"); 88 string fieldId=m.prefix() ; 89 if (fieldId.empty()) ERROR("CDomain* CDomain::get(string& id)", <<" id = "<<id<< " -> bad format id, field name is empty"); 90 string suffix=m.suffix() ; 91 CField* field=CField::get(fieldId) ; 92 return field->getAssociatedDomain(suffix) ; 93 } 94 else return CObjectFactory::GetObject<CDomain>(id).get(); 95 } 96 81 97 82 98 const std::set<StdString> & CDomain::getRelFiles(void) const
Note: See TracChangeset
for help on using the changeset viewer.