Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015 #ifndef GDCMIOD_H
00016 #define GDCMIOD_H
00017
00018 #include "gdcmTypes.h"
00019 #include "gdcmTag.h"
00020 #include "gdcmIODEntry.h"
00021
00022 #include <vector>
00023
00024 namespace gdcm
00025 {
00026 class DataSet;
00027 class Defs;
00028
00035 class GDCM_EXPORT IOD
00036 {
00037 public:
00038 typedef std::vector<IODEntry> MapIODEntry;
00039
00040 IOD() {}
00041 friend std::ostream& operator<<(std::ostream& _os, const IOD &_val);
00042
00043 void Clear() { IODInternal.clear(); }
00044
00045 void AddIODEntry(const IODEntry & iode)
00046 {
00047 IODInternal.push_back(iode);
00048 }
00049
00050 unsigned int GetNumberOfIODs() const {
00051 return IODInternal.size();
00052 }
00053
00054 const IODEntry& GetIODEntry(unsigned int idx) const
00055 {
00056 return IODInternal[idx];
00057 }
00058
00059 Type GetTypeFromTag(const Defs &defs, const Tag& tag) const;
00060
00061 private:
00062
00063
00064
00065 MapIODEntry IODInternal;
00066 };
00067
00068 inline std::ostream& operator<<(std::ostream& _os, const IOD &_val)
00069 {
00070 IOD::MapIODEntry::const_iterator it = _val.IODInternal.begin();
00071 for(;it != _val.IODInternal.end(); ++it)
00072 {
00073 _os << *it << '\n';
00074 }
00075
00076 return _os;
00077 }
00078
00079 }
00080
00081 #endif //GDCMIOD_H
00082