annotate OrthancStone/Sources/Platforms/WebAssembly/WebAssemblyOracle.h @ 2177:4d21befb1501 default tip

clarify DICOMweb version check
author Sebastien Jodogne <s.jodogne@gmail.com>
date Wed, 23 Oct 2024 19:27:56 +0200
parents 16c01cc201e7
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
1899
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
1 /**
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
2 * Stone of Orthanc
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
3 * Copyright (C) 2012-2016 Sebastien Jodogne, Medical Physics
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
4 * Department, University Hospital of Liege, Belgium
2124
16c01cc201e7 updated copyright, as Osimis is not active on Orthanc anymore
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2114
diff changeset
5 * Copyright (C) 2017-2023 Osimis S.A., Belgium
2114
c23eef785569 update year to 2024
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2077
diff changeset
6 * Copyright (C) 2021-2024 Sebastien Jodogne, ICTEAM UCLouvain, Belgium
1899
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
7 *
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
8 * This program is free software: you can redistribute it and/or
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
9 * modify it under the terms of the GNU Lesser General Public License
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
10 * as published by the Free Software Foundation, either version 3 of
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
11 * the License, or (at your option) any later version.
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
12 *
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
13 * This program is distributed in the hope that it will be useful, but
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
14 * WITHOUT ANY WARRANTY; without even the implied warranty of
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
16 * Lesser General Public License for more details.
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
17 *
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
18 * You should have received a copy of the GNU Lesser General Public
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
19 * License along with this program. If not, see
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
20 * <http://www.gnu.org/licenses/>.
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
21 **/
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
22
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
23
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
24 #pragma once
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
25
1901
184b0aeae1af fix build of sdl
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1899
diff changeset
26 #include "../../OrthancStone.h"
1899
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
27
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
28 #if !defined(ORTHANC_ENABLE_WASM)
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
29 # error The macro ORTHANC_ENABLE_WASM must be defined
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
30 #endif
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
31
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
32 #if ORTHANC_ENABLE_WASM != 1
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
33 # error This file can only compiled for WebAssembly
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
34 #endif
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
35
1901
184b0aeae1af fix build of sdl
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1899
diff changeset
36 #include "../../Messages/IObservable.h"
184b0aeae1af fix build of sdl
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1899
diff changeset
37 #include "../../Messages/IMessageEmitter.h"
184b0aeae1af fix build of sdl
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1899
diff changeset
38 #include "../../Oracle/IOracle.h"
1899
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
39
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
40 #if ORTHANC_ENABLE_DCMTK == 1
1901
184b0aeae1af fix build of sdl
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1899
diff changeset
41 # include "../../Toolbox/ParsedDicomCache.h"
1899
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
42 #endif
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
43
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
44 #include <Compatibility.h> // For ORTHANC_OVERRIDE
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
45 #include <WebServiceParameters.h>
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
46
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
47 #include <Enumerations.h>
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
48
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
49 namespace OrthancStone
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
50 {
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
51 class GetOrthancImageCommand;
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
52 class GetOrthancWebViewerJpegCommand;
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
53 class HttpCommand;
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
54 class OrthancRestApiCommand;
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
55 class ParseDicomFromWadoCommand;
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
56
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
57 class WebAssemblyOracle :
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
58 public IOracle,
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
59 public IMessageEmitter
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
60 {
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
61 private:
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
62 typedef std::map<std::string, std::string> HttpHeaders;
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
63
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
64 class TimeoutContext;
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
65 class FetchContext;
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
66 class FetchCommand;
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
67
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
68 void SetOrthancUrl(FetchCommand& command,
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
69 const std::string& uri) const;
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
70
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
71 void Execute(boost::weak_ptr<IObserver> receiver,
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
72 HttpCommand* command);
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
73
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
74 void Execute(boost::weak_ptr<IObserver> receiver,
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
75 OrthancRestApiCommand* command);
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
76
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
77 void Execute(boost::weak_ptr<IObserver> receiver,
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
78 GetOrthancImageCommand* command);
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
79
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
80 void Execute(boost::weak_ptr<IObserver> receiver,
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
81 GetOrthancWebViewerJpegCommand* command);
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
82
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
83 void Execute(boost::weak_ptr<IObserver> receiver,
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
84 ParseDicomFromWadoCommand* command);
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
85
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
86 IObservable oracleObservable_;
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
87 bool isLocalOrthanc_;
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
88 std::string localOrthancRoot_;
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
89 Orthanc::WebServiceParameters remoteOrthanc_;
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
90
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
91 #if ORTHANC_ENABLE_DCMTK == 1
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
92 std::unique_ptr<ParsedDicomCache> dicomCache_;
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
93 #endif
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
94
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
95 void ProcessFetchResult(boost::weak_ptr<IObserver>& receiver,
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
96 const std::string& answer,
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
97 const HttpHeaders& headers,
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
98 const IOracleCommand& command);
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
99
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
100 public:
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
101 WebAssemblyOracle() :
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
102 isLocalOrthanc_(false)
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
103 {
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
104 }
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
105
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
106 virtual void EmitMessage(boost::weak_ptr<IObserver> observer,
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
107 const IMessage& message) ORTHANC_OVERRIDE
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
108 {
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
109 oracleObservable_.EmitMessage(observer, message);
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
110 }
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
111
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
112 virtual bool Schedule(boost::shared_ptr<IObserver> receiver,
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
113 IOracleCommand* command) ORTHANC_OVERRIDE;
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
114
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
115 IObservable& GetOracleObservable()
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
116 {
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
117 return oracleObservable_;
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
118 }
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
119
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
120 void SetLocalOrthanc(const std::string& root)
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
121 {
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
122 isLocalOrthanc_ = true;
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
123 localOrthancRoot_ = root;
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
124 }
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
125
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
126 void SetRemoteOrthanc(const Orthanc::WebServiceParameters& orthanc)
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
127 {
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
128 isLocalOrthanc_ = false;
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
129 remoteOrthanc_ = orthanc;
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
130 }
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
131
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
132 void SetDicomCacheSize(size_t size);
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
133
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
134 class CachedInstanceAccessor : public boost::noncopyable
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
135 {
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
136 private:
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
137 #if ORTHANC_ENABLE_DCMTK == 1
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
138 std::unique_ptr<ParsedDicomCache::Reader> reader_;
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
139 #endif
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
140
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
141 public:
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
142 CachedInstanceAccessor(WebAssemblyOracle& oracle,
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
143 const std::string& sopInstanceUid);
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
144
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
145 bool IsValid() const;
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
146
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
147 #if ORTHANC_ENABLE_DCMTK == 1
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
148 const Orthanc::ParsedDicomFile& GetDicom() const;
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
149 #endif
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
150
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
151 size_t GetFileSize() const;
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
152
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
153 bool HasPixelData() const;
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
154 };
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
155 };
917500c46fe0 moved the Platform folder from the Applications folder to the Stone library itself
Alain Mazy <am@osimis.io>
parents:
diff changeset
156 }