annotate OrthancServer/Sources/ExportedResource.h @ 4741:a6b7c29f5118 openssl-3.x

compiler warning about openssl license
author Sebastien Jodogne <s.jodogne@gmail.com>
date Tue, 06 Jul 2021 09:52:15 +0200
parents f0038043fb97
children 2e71a08eea15
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
1242
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
1 /**
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
2 * Orthanc - A Lightweight, RESTful DICOM Store
1900
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1288
diff changeset
3 * Copyright (C) 2012-2016 Sebastien Jodogne, Medical Physics
1288
6e7e5ed91c2d upgrade to year 2015
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1247
diff changeset
4 * Department, University Hospital of Liege, Belgium
4437
d9473bd5ed43 upgrade to year 2021
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4045
diff changeset
5 * Copyright (C) 2017-2021 Osimis S.A., Belgium
1242
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
6 *
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
7 * This program is free software: you can redistribute it and/or
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
8 * modify it under the terms of the GNU General Public License as
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
9 * published by the Free Software Foundation, either version 3 of the
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
10 * License, or (at your option) any later version.
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
11 *
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
12 * This program is distributed in the hope that it will be useful, but
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
13 * WITHOUT ANY WARRANTY; without even the implied warranty of
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
15 * General Public License for more details.
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
16 *
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
17 * You should have received a copy of the GNU General Public License
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
18 * along with this program. If not, see <http://www.gnu.org/licenses/>.
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
19 **/
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
20
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
21
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
22 #pragma once
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
23
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
24 #include "ServerEnumerations.h"
4045
05b8fd21089c fix path
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4044
diff changeset
25 #include "../../OrthancFramework/Sources/Toolbox.h"
1242
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
26
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
27 #include <string>
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
28 #include <json/value.h>
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
29
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
30 namespace Orthanc
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
31 {
1247
32fcc5dc7562 abstraction
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1246
diff changeset
32 class ExportedResource
1242
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
33 {
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
34 private:
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
35 int64_t seq_;
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
36 ResourceType resourceType_;
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
37 std::string publicId_;
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
38 std::string modality_;
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
39 std::string date_;
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
40 std::string patientId_;
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
41 std::string studyInstanceUid_;
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
42 std::string seriesInstanceUid_;
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
43 std::string sopInstanceUid_;
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
44
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
45 public:
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
46 ExportedResource(int64_t seq,
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
47 ResourceType resourceType,
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
48 const std::string& publicId,
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
49 const std::string& modality,
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
50 const std::string& date,
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
51 const std::string& patientId,
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
52 const std::string& studyInstanceUid,
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
53 const std::string& seriesInstanceUid,
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
54 const std::string& sopInstanceUid) :
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
55 seq_(seq),
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
56 resourceType_(resourceType),
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
57 publicId_(publicId),
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
58 modality_(modality),
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
59 date_(date),
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
60 patientId_(patientId),
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
61 studyInstanceUid_(studyInstanceUid),
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
62 seriesInstanceUid_(seriesInstanceUid),
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
63 sopInstanceUid_(sopInstanceUid)
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
64 {
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
65 }
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
66
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
67 int64_t GetSeq() const
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
68 {
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
69 return seq_;
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
70 }
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
71
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
72 ResourceType GetResourceType() const
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
73 {
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
74 return resourceType_;
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
75 }
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
76
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
77 const std::string& GetPublicId() const
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
78 {
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
79 return publicId_;
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
80 }
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
81
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
82 const std::string& GetModality() const
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
83 {
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
84 return modality_;
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
85 }
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
86
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
87 const std::string& GetDate() const
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
88 {
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
89 return date_;
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
90 }
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
91
1246
54bf0f0245f4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1244
diff changeset
92 const std::string& GetPatientId() const
54bf0f0245f4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1244
diff changeset
93 {
54bf0f0245f4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1244
diff changeset
94 return patientId_;
54bf0f0245f4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1244
diff changeset
95 }
54bf0f0245f4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1244
diff changeset
96
54bf0f0245f4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1244
diff changeset
97 const std::string& GetStudyInstanceUid() const
54bf0f0245f4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1244
diff changeset
98 {
54bf0f0245f4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1244
diff changeset
99 return studyInstanceUid_;
54bf0f0245f4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1244
diff changeset
100 }
54bf0f0245f4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1244
diff changeset
101
54bf0f0245f4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1244
diff changeset
102 const std::string& GetSeriesInstanceUid() const
54bf0f0245f4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1244
diff changeset
103 {
54bf0f0245f4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1244
diff changeset
104 return seriesInstanceUid_;
54bf0f0245f4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1244
diff changeset
105 }
54bf0f0245f4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1244
diff changeset
106
54bf0f0245f4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1244
diff changeset
107 const std::string& GetSopInstanceUid() const
54bf0f0245f4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1244
diff changeset
108 {
54bf0f0245f4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1244
diff changeset
109 return sopInstanceUid_;
54bf0f0245f4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1244
diff changeset
110 }
54bf0f0245f4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1244
diff changeset
111
1247
32fcc5dc7562 abstraction
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1246
diff changeset
112 void Format(Json::Value& item) const;
1242
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
113 };
58e6a89c3ef4 refactoring
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
114 }