Changeset 2386 for XIOS3/trunk/src/attribute_map.cpp
- Timestamp:
- 07/26/22 15:26:52 (23 months ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
XIOS3/trunk/src/attribute_map.cpp
r2146 r2386 269 269 } 270 270 271 /*! 272 Compute the hash value of current attribute map excluding some attributs. 273 \param [in] excludedAttrs attribute to be excluded from hash computation 274 */ 275 int CAttributeMap::computeGlobalAttributesHash(const vector<StdString>& excludedAttrs) 276 { 277 int attrs_hash( 0 ); 278 typedef std::pair<StdString, CAttribute*> StdStrAttPair; 279 280 SuperClassMap::const_iterator it = this->begin(), end = this->end(); 281 for (; it != end; it++) 282 { 283 const StdStrAttPair& el = *it; 284 if ( std::find( excludedAttrs.begin(), excludedAttrs.end(), el.first ) == excludedAttrs.end() ) 285 { 286 if (this->hasAttribute(el.first)) 287 { 288 if (!el.second->isEmpty()) 289 { 290 attrs_hash += el.second->computeHash(); 291 } 292 } 293 } 294 } 295 return attrs_hash; 296 } 297 271 298 //--------------------------------------------------------------- 272 299 /*
Note: See TracChangeset
for help on using the changeset viewer.