00001 
00002 
00003 
00004 
00005 
00006 
00007 
00008 
00009 
00010 
00011 
00012 
00013 
00014 
00015 
00016 
00017 
00018 
00019 #ifndef GDCMPATIENT_H
00020 #define GDCMPATIENT_H
00021 
00022 #include "gdcmDicomDirObject.h"
00023 
00024 namespace gdcm 
00025 {
00026 class DicomDirStudy;
00027 
00028 
00029 typedef std::list<DicomDirStudy*> ListDicomDirStudy;
00030 
00031 
00036 class GDCM_EXPORT DicomDirPatient : public DicomDirObject 
00037 {
00038    gdcmTypeMacro(DicomDirPatient);
00039 
00040 public:
00042    static DicomDirPatient *New(bool empty=false) {return new DicomDirPatient(empty);}
00043 
00044    void Print(std::ostream &os = std::cout, std::string const &indent = "" );
00045    void WriteContent(std::ofstream *fp, FileType t);
00046   
00047    
00049    void AddStudy(DicomDirStudy *obj) { Studies.push_back(obj); }
00050    DicomDirStudy *NewStudy(); 
00051    void ClearStudy();
00052 
00053    DicomDirStudy *GetFirstStudy();
00054    DicomDirStudy *GetNextStudy();
00055    DicomDirStudy *GetLastStudy();
00056 
00057    virtual void Copy(DocEntrySet *set);
00058 
00059 protected:
00060    DicomDirPatient(bool empty=false); 
00061    ~DicomDirPatient();
00062 
00063 private:
00065    ListDicomDirStudy Studies;
00067    ListDicomDirStudy::iterator ItStudy;
00068 };
00069 } 
00070 
00071 
00072 #endif