annotate OrthancServer/Plugins/Samples/MultitenantDicom/DicomFilter.h @ 5371:a8385880902f

fix incorrect license for MultitenantDicom plugin
author Sebastien Jodogne <s.jodogne@gmail.com>
date Wed, 16 Aug 2023 09:14:17 +0200
parents 7cb1b851f5c8
children 48b8dae6dc77
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
5273
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
1 /**
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
2 * Orthanc - A Lightweight, RESTful DICOM Store
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
3 * Copyright (C) 2012-2016 Sebastien Jodogne, Medical Physics
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
4 * Department, University Hospital of Liege, Belgium
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
5 * Copyright (C) 2017-2023 Osimis S.A., Belgium
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
6 * Copyright (C) 2021-2023 Sebastien Jodogne, ICTEAM UCLouvain, Belgium
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
7 *
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
8 * This program is free software: you can redistribute it and/or
5371
a8385880902f fix incorrect license for MultitenantDicom plugin
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 5273
diff changeset
9 * modify it under the terms of the GNU General Public License as
a8385880902f fix incorrect license for MultitenantDicom plugin
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 5273
diff changeset
10 * published by the Free Software Foundation, either version 3 of the
a8385880902f fix incorrect license for MultitenantDicom plugin
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 5273
diff changeset
11 * License, or (at your option) any later version.
5273
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
12 *
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
13 * This program is distributed in the hope that it will be useful, but
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
14 * WITHOUT ANY WARRANTY; without even the implied warranty of
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
5371
a8385880902f fix incorrect license for MultitenantDicom plugin
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 5273
diff changeset
16 * General Public License for more details.
5273
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
17 *
5371
a8385880902f fix incorrect license for MultitenantDicom plugin
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 5273
diff changeset
18 * You should have received a copy of the GNU General Public License
a8385880902f fix incorrect license for MultitenantDicom plugin
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 5273
diff changeset
19 * along with this program. If not, see <http://www.gnu.org/licenses/>.
5273
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
20 **/
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
21
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
22
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
23 #pragma once
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
24
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
25 #include "../../../../OrthancFramework/Sources/Compatibility.h"
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
26 #include "../../../../OrthancFramework/Sources/DicomNetworking/IApplicationEntityFilter.h"
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
27
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
28 #include <boost/thread/shared_mutex.hpp>
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
29
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
30
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
31 class DicomFilter : public Orthanc::IApplicationEntityFilter
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
32 {
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
33 private:
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
34 boost::shared_mutex mutex_;
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
35
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
36 bool alwaysAllowEcho_;
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
37 bool alwaysAllowFind_;
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
38 bool alwaysAllowMove_;
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
39 bool alwaysAllowStore_;
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
40 bool unknownSopClassAccepted_;
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
41 bool isStrict_;
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
42 bool checkModalityHost_;
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
43
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
44 bool hasAcceptedTransferSyntaxes_;
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
45 std::set<Orthanc::DicomTransferSyntax> acceptedTransferSyntaxes_;
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
46
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
47 public:
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
48 DicomFilter();
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
49
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
50 virtual bool IsAllowedConnection(const std::string& remoteIp,
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
51 const std::string& remoteAet,
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
52 const std::string& calledAet) ORTHANC_OVERRIDE;
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
53
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
54 virtual bool IsAllowedRequest(const std::string& remoteIp,
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
55 const std::string& remoteAet,
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
56 const std::string& calledAet,
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
57 Orthanc::DicomRequestType type) ORTHANC_OVERRIDE;
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
58
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
59 virtual void GetAcceptedTransferSyntaxes(std::set<Orthanc::DicomTransferSyntax>& target,
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
60 const std::string& remoteIp,
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
61 const std::string& remoteAet,
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
62 const std::string& calledAet) ORTHANC_OVERRIDE;
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
63
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
64 virtual bool IsUnknownSopClassAccepted(const std::string& remoteIp,
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
65 const std::string& remoteAet,
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
66 const std::string& calledAet) ORTHANC_OVERRIDE;
7cb1b851f5c8 Added a sample plugin bringing multitenant DICOM support through labels
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
67 };