Mercurial > hg > orthanc
comparison Core/DicomFormat/DicomMap.h @ 1364:111e23bb4904 query-retrieve
integration mainline->query-retrieve
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Thu, 21 May 2015 16:58:30 +0200 |
parents | 67e6400fca03 0649c5aef34a |
children | ec66a16aa398 |
comparison
equal
deleted
inserted
replaced
953:f894be6e7cc1 | 1364:111e23bb4904 |
---|---|
1 /** | 1 /** |
2 * Orthanc - A Lightweight, RESTful DICOM Store | 2 * Orthanc - A Lightweight, RESTful DICOM Store |
3 * Copyright (C) 2012-2014 Medical Physics Department, CHU of Liege, | 3 * Copyright (C) 2012-2015 Sebastien Jodogne, Medical Physics |
4 * Belgium | 4 * Department, University Hospital of Liege, Belgium |
5 * | 5 * |
6 * This program is free software: you can redistribute it and/or | 6 * This program is free software: you can redistribute it and/or |
7 * modify it under the terms of the GNU General Public License as | 7 * modify it under the terms of the GNU General Public License as |
8 * published by the Free Software Foundation, either version 3 of the | 8 * published by the Free Software Foundation, either version 3 of the |
9 * License, or (at your option) any later version. | 9 * License, or (at your option) any later version. |
76 ~DicomMap() | 76 ~DicomMap() |
77 { | 77 { |
78 Clear(); | 78 Clear(); |
79 } | 79 } |
80 | 80 |
81 size_t GetSize() const | |
82 { | |
83 return map_.size(); | |
84 } | |
85 | |
81 DicomMap* Clone() const; | 86 DicomMap* Clone() const; |
87 | |
88 void Assign(const DicomMap& other); | |
82 | 89 |
83 void Clear(); | 90 void Clear(); |
84 | 91 |
85 void SetValue(uint16_t group, | 92 void SetValue(uint16_t group, |
86 uint16_t element, | 93 uint16_t element, |
123 return GetValue(DicomTag(group, element)); | 130 return GetValue(DicomTag(group, element)); |
124 } | 131 } |
125 | 132 |
126 const DicomValue& GetValue(const DicomTag& tag) const; | 133 const DicomValue& GetValue(const DicomTag& tag) const; |
127 | 134 |
135 // DO NOT delete the returned value! | |
128 const DicomValue* TestAndGetValue(uint16_t group, uint16_t element) const | 136 const DicomValue* TestAndGetValue(uint16_t group, uint16_t element) const |
129 { | 137 { |
130 return TestAndGetValue(DicomTag(group, element)); | 138 return TestAndGetValue(DicomTag(group, element)); |
131 } | 139 } |
132 | 140 |
141 // DO NOT delete the returned value! | |
133 const DicomValue* TestAndGetValue(const DicomTag& tag) const; | 142 const DicomValue* TestAndGetValue(const DicomTag& tag) const; |
134 | 143 |
135 void Remove(const DicomTag& tag); | 144 void Remove(const DicomTag& tag); |
136 | 145 |
137 void ExtractPatientInformation(DicomMap& result) const; | 146 void ExtractPatientInformation(DicomMap& result) const; |
159 | 168 |
160 static void GetMainDicomTags(std::set<DicomTag>& result, ResourceType level); | 169 static void GetMainDicomTags(std::set<DicomTag>& result, ResourceType level); |
161 | 170 |
162 static void GetMainDicomTags(std::set<DicomTag>& result); | 171 static void GetMainDicomTags(std::set<DicomTag>& result); |
163 | 172 |
164 void ExtractMainDicomTagsForLevel(DicomMap& result, | 173 void Print(FILE* fp) const; |
165 ResourceType level) const; | 174 |
175 void GetTags(std::set<DicomTag>& tags) const; | |
166 }; | 176 }; |
167 } | 177 } |