1 /*=========================================================================
4 Module: $RCSfile: gdcmDicomDirImage.cxx,v $
6 Date: $Date: 2007/05/23 14:18:08 $
7 Version: $Revision: 1.25 $
9 Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
10 l'Image). All rights reserved. See Doc/License.txt or
11 http://www.creatis.insa-lyon.fr/Public/Gdcm/License.html for details.
13 This software is distributed WITHOUT ANY WARRANTY; without even
14 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
15 PURPOSE. See the above copyright notices for more information.
17 =========================================================================*/
19 #include "gdcmDicomDirImage.h"
20 #include "gdcmGlobal.h"
21 #include "gdcmDataEntry.h"
23 namespace GDCM_NAME_SPACE
25 //-----------------------------------------------------------------------------
26 // Constructor / Destructor
29 * \note End user must use : DicomDirSerie::NewImage()
31 DicomDirImage::DicomDirImage(bool empty):
36 ListDicomDirImageElem const &elemList =
37 Global::GetDicomDirElements()->GetDicomDirImageElements();
43 * \brief Canonical destructor.
45 DicomDirImage::~DicomDirImage()
49 //-----------------------------------------------------------------------------
52 //-----------------------------------------------------------------------------
55 //-----------------------------------------------------------------------------
58 //-----------------------------------------------------------------------------
61 * \brief Prints the Object
62 * @param os ostream to write to
63 * @param indent Indentation string to be prepended during printing
66 void DicomDirImage::Print(std::ostream &os, std::string const & )
69 for(ListDocEntry::iterator i = DocEntries.begin();
73 if ( (*i)->GetGroup() == 0x0004 && (*i)->GetElement() == 0x1500 )
75 if( dynamic_cast<DataEntry *>(*i) )
76 os << (dynamic_cast<DataEntry *>(*i))->GetString();
81 DicomDirObject::Print(os);
84 //-----------------------------------------------------------------------------
85 } // end namespace gdcm