comparison Framework/Plugins/IDatabaseBackendOutput.h @ 202:2def2df94f94

reorganization
author Sebastien Jodogne <s.jodogne@gmail.com>
date Thu, 18 Mar 2021 17:00:38 +0100
parents
children 2089d4071408
comparison
equal deleted inserted replaced
201:42990b2dd51b 202:2def2df94f94
1 /**
2 * Orthanc - A Lightweight, RESTful DICOM Store
3 * Copyright (C) 2012-2016 Sebastien Jodogne, Medical Physics
4 * Department, University Hospital of Liege, Belgium
5 * Copyright (C) 2017-2021 Osimis S.A., Belgium
6 *
7 * This program is free software: you can redistribute it and/or
8 * modify it under the terms of the GNU Affero General Public License
9 * as published by the Free Software Foundation, either version 3 of
10 * the License, or (at your option) any later version.
11 *
12 * This program is distributed in the hope that it will be useful, but
13 * WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 * Affero General Public License for more details.
16 *
17 * You should have received a copy of the GNU Affero General Public License
18 * along with this program. If not, see <http://www.gnu.org/licenses/>.
19 **/
20
21
22 #pragma once
23
24 #include "../../Resources/Orthanc/Databases/DatabaseConstraint.h"
25
26 namespace OrthancPlugins
27 {
28 class IDatabaseBackendOutput : public boost::noncopyable
29 {
30 public:
31 class IFactory : public boost::noncopyable
32 {
33 public:
34 virtual ~IFactory()
35 {
36 }
37
38 virtual IDatabaseBackendOutput* CreateOutput() = 0;
39 };
40
41 virtual ~IDatabaseBackendOutput()
42 {
43 }
44
45 virtual void SignalDeletedAttachment(const std::string& uuid,
46 int32_t contentType,
47 uint64_t uncompressedSize,
48 const std::string& uncompressedHash,
49 int32_t compressionType,
50 uint64_t compressedSize,
51 const std::string& compressedHash) = 0;
52
53 virtual void SignalDeletedResource(const std::string& publicId,
54 OrthancPluginResourceType resourceType) = 0;
55
56 virtual void SignalRemainingAncestor(const std::string& ancestorId,
57 OrthancPluginResourceType ancestorType) = 0;
58
59 virtual void AnswerAttachment(const std::string& uuid,
60 int32_t contentType,
61 uint64_t uncompressedSize,
62 const std::string& uncompressedHash,
63 int32_t compressionType,
64 uint64_t compressedSize,
65 const std::string& compressedHash) = 0;
66
67 virtual void AnswerChange(int64_t seq,
68 int32_t changeType,
69 OrthancPluginResourceType resourceType,
70 const std::string& publicId,
71 const std::string& date) = 0;
72
73 virtual void AnswerDicomTag(uint16_t group,
74 uint16_t element,
75 const std::string& value) = 0;
76
77 virtual void AnswerExportedResource(int64_t seq,
78 OrthancPluginResourceType resourceType,
79 const std::string& publicId,
80 const std::string& modality,
81 const std::string& date,
82 const std::string& patientId,
83 const std::string& studyInstanceUid,
84 const std::string& seriesInstanceUid,
85 const std::string& sopInstanceUid) = 0;
86 #if ORTHANC_PLUGINS_HAS_DATABASE_CONSTRAINT == 1
87 virtual void AnswerMatchingResource(const std::string& resourceId) = 0;
88 #endif
89
90 #if ORTHANC_PLUGINS_HAS_DATABASE_CONSTRAINT == 1
91 virtual void AnswerMatchingResource(const std::string& resourceId,
92 const std::string& someInstanceId) = 0;
93 #endif
94 };
95 }