X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=src%2FgdcmDicomDirPatient.cxx;h=3cc33bc7e98ddddfc8203582c7258948952e878c;hb=a5477cb88aa763acdea8f3fbd6e58d70cec8f42e;hp=33ae75b94f4b49d48789b20200f548e947b19ca7;hpb=30d2b02b938fe912d866b40ca2b9842961481ab2;p=gdcm.git diff --git a/src/gdcmDicomDirPatient.cxx b/src/gdcmDicomDirPatient.cxx index 33ae75b9..3cc33bc7 100644 --- a/src/gdcmDicomDirPatient.cxx +++ b/src/gdcmDicomDirPatient.cxx @@ -1,5 +1,21 @@ -// gdcmDicomDirPatient.cxx -//----------------------------------------------------------------------------- +/*========================================================================= + + Program: gdcm + Module: $RCSfile: gdcmDicomDirPatient.cxx,v $ + Language: C++ + Date: $Date: 2004/08/01 02:39:09 $ + 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 "gdcmDicomDirPatient.h" #include "gdcmDicomDirElement.h" #include "gdcmGlobal.h" @@ -18,7 +34,12 @@ gdcmDicomDirPatient::gdcmDicomDirPatient(gdcmSQItem *s, TagDocEntryHT *ptagHT): { docEntries = s->GetDocEntries(); } - +/** + * \ingroup gdcmDicomDirPatient + * \brief Constructor + * @param ptagHT pointer to the HTable (gdcmObject needs it + * to build the gdcmHeaderEntries) + */ gdcmDicomDirPatient::gdcmDicomDirPatient(TagDocEntryHT *ptagHT): gdcmObject(ptagHT) { @@ -29,7 +50,8 @@ gdcmDicomDirPatient::gdcmDicomDirPatient(TagDocEntryHT *ptagHT): */ gdcmDicomDirPatient::~gdcmDicomDirPatient() { - for(ListDicomDirStudy::iterator cc = studies.begin();cc != studies.end();++cc) + for(ListDicomDirStudy::iterator cc = studies.begin(); + cc != studies.end(); ++cc) { delete *cc; } @@ -44,12 +66,13 @@ gdcmDicomDirPatient::~gdcmDicomDirPatient() */ void gdcmDicomDirPatient::Print(std::ostream &os) { - os<<"PATIENT"<SetPrintLevel(printLevel); + (*cc)->SetPrintLevel(PrintLevel); (*cc)->Print(os); } } @@ -62,17 +85,16 @@ void gdcmDicomDirPatient::Print(std::ostream &os) * \brief adds a new Patient at the begining of the PatientList * of a partially created DICOMDIR */ -gdcmDicomDirStudy * gdcmDicomDirPatient::NewStudy(void) { - std::list elemList; - elemList=gdcmGlobal::GetDicomDirElements()->GetDicomDirStudyElements(); +gdcmDicomDirStudy * gdcmDicomDirPatient::NewStudy() +{ + std::list elemList = + gdcmGlobal::GetDicomDirElements()->GetDicomDirStudyElements(); - gdcmDicomDirStudy *st = new gdcmDicomDirStudy( ptagHT); + gdcmDicomDirStudy *st = new gdcmDicomDirStudy( PtagHT ); st->FillObject(elemList); studies.push_front(st); return st; - - } //-----------------------------------------------------------------------------