X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=src%2FgdcmDicomDirSerie.cxx;h=ecdb07c29ddcd296011de71cf4b276e388f02732;hb=15915dd3b6d2c5e64f4a06a1516ae51b3cb9944a;hp=a9f2d9654bb59439416fc37cc949e0ff97b19575;hpb=22f785a2627d1e7823701193bd7624739a3e033b;p=gdcm.git diff --git a/src/gdcmDicomDirSerie.cxx b/src/gdcmDicomDirSerie.cxx index a9f2d965..ecdb07c2 100644 --- a/src/gdcmDicomDirSerie.cxx +++ b/src/gdcmDicomDirSerie.cxx @@ -1,22 +1,49 @@ -// gdcmDicomDirSerie.cxx -//----------------------------------------------------------------------------- +/*========================================================================= + + Program: gdcm + Module: $RCSfile: gdcmDicomDirSerie.cxx,v $ + Language: C++ + Date: $Date: 2004/06/20 18:08:47 $ + Version: $Revision: 1.10 $ + + Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de + l'Image). All rights reserved. See Doc/License.txt or + http://www.creatis.insa-lyon.fr/Public/Gdcm/License.htm for details. + + This software is distributed WITHOUT ANY WARRANTY; without even + the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR + PURPOSE. See the above copyright notices for more information. + +=========================================================================*/ + #include "gdcmDicomDirSerie.h" +#include "gdcmDicomDirElement.h" +#include "gdcmGlobal.h" //----------------------------------------------------------------------------- // Constructor / Destructor /** - * \ingroup gdcmDicomDirSerie - * \brief - * @param begin iterator of begin for the object - * @param end iterator of end for the object + * \brief Constructor + * @param s SQ Item holding the elements related to this "SERIE" part + * @param ptagHT pointer to the HTable (gdcmObject needs it + * to build the gdcmDocEntries) */ -gdcmDicomDirSerie::gdcmDicomDirSerie(ListTag::iterator begin,ListTag::iterator end): - gdcmObject(begin,end) +gdcmDicomDirSerie::gdcmDicomDirSerie(gdcmSQItem *s, TagDocEntryHT *ptagHT): + gdcmObject(ptagHT) { + docEntries = s->GetDocEntries(); } /** - * \ingroup gdcmDicomDirSerie + * \brief Constructor + * @param ptagHT pointer to the HTable (gdcmObject needs it + * to build the gdcmDocEntries) + */ +gdcmDicomDirSerie::gdcmDicomDirSerie(TagDocEntryHT *ptagHT): + gdcmObject(ptagHT) +{ +} +/** * \brief Canonical destructor. */ gdcmDicomDirSerie::~gdcmDicomDirSerie() @@ -30,7 +57,6 @@ gdcmDicomDirSerie::~gdcmDicomDirSerie() //----------------------------------------------------------------------------- // Print /** - * \ingroup gdcmDicomDirSerie * \brief Prints the Object * @return */ @@ -48,7 +74,18 @@ void gdcmDicomDirSerie::Print(std::ostream &os) //----------------------------------------------------------------------------- // Public - +/** + * \brief adds a new Image to a partially created DICOMDIR + */ +gdcmDicomDirImage * gdcmDicomDirSerie::NewImage(void) { + std::list elemList; + elemList=gdcmGlobal::GetDicomDirElements()->GetDicomDirImageElements(); + + gdcmDicomDirImage *st = new gdcmDicomDirImage(ptagHT); + FillObject(elemList); + images.push_front(st); + return st; +} //----------------------------------------------------------------------------- // Protected