comparison OrthancFramework/Sources/DicomFormat/DicomMap.h @ 5195:32df369198ac

fix /tools/reset crashing when ExtraMainDicomTags were defined
author Alain Mazy <am@osimis.io>
date Tue, 28 Mar 2023 10:48:13 +0200
parents 0ea402b4d901
children 138e9d0c08c1
comparison
equal deleted inserted replaced
5185:0ea402b4d901 5195:32df369198ac
29 29
30 #include <set> 30 #include <set>
31 #include <map> 31 #include <map>
32 #include <json/value.h> 32 #include <json/value.h>
33 33
34 #if ORTHANC_BUILD_UNIT_TESTS == 1
35 # include <gtest/gtest_prod.h>
36 #endif
37
38 namespace Orthanc 34 namespace Orthanc
39 { 35 {
40 class ORTHANC_PUBLIC DicomMap : public boost::noncopyable 36 class ORTHANC_PUBLIC DicomMap : public boost::noncopyable
41 { 37 {
42 public: 38 public:
46 class MainDicomTagsConfiguration; 42 class MainDicomTagsConfiguration;
47 friend class DicomArray; 43 friend class DicomArray;
48 friend class FromDcmtkBridge; 44 friend class FromDcmtkBridge;
49 friend class ParsedDicomFile; 45 friend class ParsedDicomFile;
50 46
51 #if ORTHANC_BUILD_UNIT_TESTS == 1
52 friend class DicomMapMainTagsTests;
53 #endif
54
55 Content content_; 47 Content content_;
56 48
57 // Warning: This takes the ownership of "value" 49 // Warning: This takes the ownership of "value"
58 void SetValueInternal(uint16_t group, 50 void SetValueInternal(uint16_t group,
59 uint16_t element, 51 uint16_t element,
60 DicomValue* value); 52 DicomValue* value);
61 53
62 // used for unit tests only
63 static void ResetDefaultMainDicomTags();
64
65 public: 54 public:
66 ~DicomMap(); 55 ~DicomMap();
56
57 static void ResetDefaultMainDicomTags();
67 58
68 size_t GetSize() const; 59 size_t GetSize() const;
69 60
70 DicomMap* Clone() const; 61 DicomMap* Clone() const;
71 62