1 /*=========================================================================
4 Module: $RCSfile: gdcmDicomDirMeta.cxx,v $
6 Date: $Date: 2005/01/18 14:28:32 $
7 Version: $Revision: 1.23 $
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 "gdcmDicomDirMeta.h"
20 #include "gdcmDocument.h"
21 #include "gdcmDocEntry.h"
26 //-----------------------------------------------------------------------------
27 // Constructor / Destructor
32 DicomDirMeta::DicomDirMeta():
38 * \brief Canonical destructor.
40 DicomDirMeta::~DicomDirMeta()
44 //-----------------------------------------------------------------------------
47 * \brief Prints the Meta Elements
48 * @param os ostream to write to
49 * @param indent indent
51 void DicomDirMeta::Print(std::ostream &os, std::string const & )
53 os << "META" << std::endl;
54 // warning : META doesn't behave exactly like a Objet
55 for (ListDocEntry::iterator i = DocEntries.begin();
56 i != DocEntries.end();
59 (*i)->SetPrintLevel(PrintLevel);
66 //-----------------------------------------------------------------------------
71 * \brief Writes the Meta Elements
72 * @param fp ofstream to write to
76 void DicomDirMeta::WriteContent(std::ofstream *fp, FileType t)
78 for (ListDocEntry::iterator i = DocEntries.begin();
79 i != DocEntries.end();
82 (*i)->WriteContent(fp, t);
86 //-----------------------------------------------------------------------------
89 //-----------------------------------------------------------------------------
92 //-----------------------------------------------------------------------------
94 } // end namespace gdcm