]> Creatis software - gdcm.git/blobdiff - src/gdcmUtil.cxx
Update, according to David Clunie's site
[gdcm.git] / src / gdcmUtil.cxx
index fb1f87fb248565e7647eb571759083d65cd66a4e..faad02548843d592f30abff1a2bfc3bdb439a2f2 100644 (file)
@@ -52,23 +52,26 @@ void gdcmDebug::Exit(int a) {
 }
 
 //-----------------------------------------------------------------------------
-gdcmVR      *gdcmGlobal::VR    = (gdcmVR *)0;
-gdcmTS      *gdcmGlobal::TS    = (gdcmTS *)0;
-gdcmDictSet *gdcmGlobal::Dicts = (gdcmDictSet *)0;
+gdcmDictSet         *gdcmGlobal::Dicts  = (gdcmDictSet *)0;
+gdcmVR              *gdcmGlobal::VR     = (gdcmVR *)0;
+gdcmTS              *gdcmGlobal::TS     = (gdcmTS *)0;
+gdcmDicomDirElement *gdcmGlobal::ddElem = (gdcmDicomDirElement *)0;
 gdcmGlobal gdcmGlob;
 
 gdcmGlobal::gdcmGlobal(void) {
    if (VR || TS || Dicts)
       dbg.Verbose(0, "gdcmGlobal::gdcmGlobal : VR or TS or Dicts already allocated");
+   Dicts = new gdcmDictSet();
    VR = new gdcmVR();
    TS = new gdcmTS();
-   Dicts = new gdcmDictSet();
+   ddElem = new gdcmDicomDirElement();
 }
 
 gdcmGlobal::~gdcmGlobal() {
+   delete Dicts;
    delete VR;
    delete TS;
-   delete Dicts;
+   delete ddElem;
 }
 
 gdcmVR *gdcmGlobal::GetVR(void) {
@@ -83,6 +86,10 @@ gdcmDictSet *gdcmGlobal::GetDicts(void) {
    return Dicts;
 }
 
+gdcmDicomDirElement *gdcmGlobal::GetDicomDirElements(void) {
+   return ddElem;
+}
+
 //-----------------------------------------------------------------------------
 // Because is not yet available in g++2.96
 std::istream& eatwhite(std::istream& is) {