comparison OrthancFramework/Sources/DicomNetworking/DicomFindAnswers.cpp @ 4296:3b70a2e6a06c

moving inline methods to source files for ABI compatibility
author Sebastien Jodogne <s.jodogne@gmail.com>
date Thu, 05 Nov 2020 15:52:28 +0100
parents 0034f855c023
children d9473bd5ed43
comparison
equal deleted inserted replaced
4295:90f91b78d708 4296:3b70a2e6a06c
56 isWorklist_(isWorklist), 56 isWorklist_(isWorklist),
57 complete_(true) 57 complete_(true)
58 { 58 {
59 } 59 }
60 60
61 DicomFindAnswers::~DicomFindAnswers()
62 {
63 Clear();
64 }
65
66 Encoding DicomFindAnswers::GetEncoding() const
67 {
68 return encoding_;
69 }
70
61 71
62 void DicomFindAnswers::SetEncoding(Encoding encoding) 72 void DicomFindAnswers::SetEncoding(Encoding encoding)
63 { 73 {
64 for (size_t i = 0; i < answers_.size(); i++) 74 for (size_t i = 0; i < answers_.size(); i++)
65 { 75 {
80 else 90 else
81 { 91 {
82 // This set of answers is not empty anymore, cannot change its type 92 // This set of answers is not empty anymore, cannot change its type
83 throw OrthancException(ErrorCode_BadSequenceOfCalls); 93 throw OrthancException(ErrorCode_BadSequenceOfCalls);
84 } 94 }
95 }
96
97 bool DicomFindAnswers::IsWorklist() const
98 {
99 return isWorklist_;
85 } 100 }
86 101
87 102
88 void DicomFindAnswers::Clear() 103 void DicomFindAnswers::Clear()
89 { 104 {
123 138
124 void DicomFindAnswers::Add(const void* dicom, 139 void DicomFindAnswers::Add(const void* dicom,
125 size_t size) 140 size_t size)
126 { 141 {
127 AddAnswerInternal(new ParsedDicomFile(dicom, size)); 142 AddAnswerInternal(new ParsedDicomFile(dicom, size));
143 }
144
145 size_t DicomFindAnswers::GetSize() const
146 {
147 return answers_.size();
128 } 148 }
129 149
130 150
131 ParsedDicomFile& DicomFindAnswers::GetAnswer(size_t index) const 151 ParsedDicomFile& DicomFindAnswers::GetAnswer(size_t index) const
132 { 152 {
198 target.append(answer); 218 target.append(answer);
199 } 219 }
200 } 220 }
201 221
202 222
223 bool DicomFindAnswers::IsComplete() const
224 {
225 return complete_;
226 }
227
228 void DicomFindAnswers::SetComplete(bool isComplete)
229 {
230 complete_ = isComplete;
231 }
232
233
203 #if ORTHANC_BUILDING_FRAMEWORK_LIBRARY == 1 234 #if ORTHANC_BUILDING_FRAMEWORK_LIBRARY == 1
204 void DicomFindAnswers::Add(ParsedDicomFile& dicom) 235 void DicomFindAnswers::Add(ParsedDicomFile& dicom)
205 { 236 {
206 return Add(const_cast<const ParsedDicomFile&>(dicom)); 237 return Add(const_cast<const ParsedDicomFile&>(dicom));
207 } 238 }