]> Creatis software - gdcm.git/blob - src/gdcmDictEntry.h
UpdateGroupLength re-written using H-Table
[gdcm.git] / src / gdcmDictEntry.h
1 // gdcmDictEntry.h
2
3 #ifndef GDCMDICTENTRY_H
4 #define GDCMDICTENTRY_H
5
6 #include "gdcmCommon.h"
7
8 class GDCM_EXPORT gdcmDictEntry {
9 private:
10         guint16 group;    // e.g. 0x0010  // FIXME : s'en sert-on qq part
11         guint16 element;  // e.g. 0x0103  // si ce n'est pour fabriquer la TagKey ?
12         string  vr;       // Value Representation i.e. some clue about the nature
13                           // of the data represented e.g. "FD" short for
14                           // "Floating Point Double"
15         // CLEANME: find the official dicom name for this field !
16         string  fourth;   // Fourth field containing some semantics. (Group Name abbr.)
17         string  name;     // e.g. "Patient_Name"
18         TagKey  key;      // Redundant with (group, element) but we add it
19                           // on efficiency purposes.
20         // DCMTK has many fields for handling a DictEntry (see below). What are the
21         // relevant ones for gdcmlib ?
22         //      struct DBI_SimpleEntry {
23         //         Uint16 upperGroup;
24         //         Uint16 upperElement;
25         //         DcmEVR evr;
26         //         const char* tagName;
27         //         int vmMin;
28         //         int vmMax;
29         //         const char* standardVersion;
30         //         DcmDictRangeRestriction groupRestriction;
31         //         DcmDictRangeRestriction elementRestriction;
32         //       };
33 public:
34         gdcmDictEntry(guint16 group, 
35                       guint16 element,
36                       string vr     = "Unknown",
37                       string fourth = "Unknown",
38                       string name   = "Unknown");
39                          
40         // fabrique une 'clĂ©' par concatĂ©nation du numGroupe et du numElement
41         static TagKey TranslateToKey(guint16 group, guint16 element);
42         
43         guint16 GetGroup(void)  { return group; };
44         guint16 GetElement(void){return element;};
45         string  GetVR(void)     {return vr;     };
46         void    SetVR(string);
47         void    SetKey(string k){ key = k;     }
48         bool    IsVrUnknown(void);
49         string  GetFourth(void) {return fourth;};
50         string  GetName(void)   {return name;  };
51         string  GetKey(void)    {return key;   };
52 };
53
54 #endif