Program: gdcm
Module: $RCSfile: gdcmElementSet.cxx,v $
Language: C++
- Date: $Date: 2005/01/24 16:10:52 $
- Version: $Revision: 1.49 $
+ Date: $Date: 2005/01/25 11:11:59 $
+ Version: $Revision: 1.50 $
Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
l'Image). All rights reserved. See Doc/License.txt or
*/
ElementSet::~ElementSet()
{
- for(TagDocEntryHT::iterator cc = TagHT.begin();cc != TagHT.end(); ++cc)
- {
- if ( cc->second )
- {
- delete cc->second;
- }
- }
- TagHT.clear();
+ ClearEntry();
}
//-----------------------------------------------------------------------------
return 0;
}
-
-//-----------------------------------------------------------------------------
-// Protected
-
/**
* \brief Checks if a given Dicom Element exists within the H table
* @param group Group number of the searched Dicom Element
return ((ValEntry *)TagHT.find(key)->second)->GetValue();
}
-
-//-----------------------------------------------------------------------------
-// Private
+/**
+ * \brief delete all entries in the ElementSet
+ */
+void ElementSet::ClearEntry()
+{
+ for(TagDocEntryHT::iterator cc = TagHT.begin();cc != TagHT.end(); ++cc)
+ {
+ if ( cc->second )
+ {
+ delete cc->second;
+ }
+ }
+ TagHT.clear();
+}
/**
* \brief add a new Dicom Element pointer to the H Table
return NULL;
}
-
/**
* \brief Get the larst entry while visiting the DocEntrySet
* \return The last DocEntry if found, otherwhise NULL
return NULL;
}
+//-----------------------------------------------------------------------------
+// Protected
+
+//-----------------------------------------------------------------------------
+// Private
//-----------------------------------------------------------------------------
} // end namespace gdcm