Mercurial > hg > orthanc
annotate OrthancFramework/Sources/HttpServer/WebDavStorage.h @ 4709:a9a75281cae9 openssl-3.x
fix build on MSVC 2008 32bit
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Tue, 22 Jun 2021 10:26:27 +0200 |
parents | d9473bd5ed43 |
children | 7053502fbf97 |
rev | line source |
---|---|
4230 | 1 /** |
2 * Orthanc - A Lightweight, RESTful DICOM Store | |
3 * Copyright (C) 2012-2016 Sebastien Jodogne, Medical Physics | |
4 * Department, University Hospital of Liege, Belgium | |
4437
d9473bd5ed43
upgrade to year 2021
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
4253
diff
changeset
|
5 * Copyright (C) 2017-2021 Osimis S.A., Belgium |
4230 | 6 * |
7 * This program is free software: you can redistribute it and/or | |
8 * modify it under the terms of the GNU Lesser 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 * Lesser General Public License for more details. | |
16 * | |
17 * You should have received a copy of the GNU Lesser General Public | |
18 * License along with this program. If not, see | |
19 * <http://www.gnu.org/licenses/>. | |
20 **/ | |
21 | |
22 | |
23 | |
24 #pragma once | |
25 | |
26 #include "IWebDavBucket.h" | |
27 | |
28 #include <boost/thread/recursive_mutex.hpp> | |
29 | |
30 namespace Orthanc | |
31 { | |
32 class WebDavStorage : public IWebDavBucket | |
33 { | |
34 private: | |
35 class StorageFile; | |
36 class StorageFolder; | |
37 | |
38 StorageFolder* LookupParentFolder(const std::vector<std::string>& path); | |
39 | |
40 boost::shared_ptr<StorageFolder> root_; // PImpl | |
41 boost::recursive_mutex mutex_; | |
42 bool isMemory_; | |
43 | |
44 public: | |
4253 | 45 explicit WebDavStorage(bool isMemory); |
4230 | 46 |
47 virtual bool IsExistingFolder(const std::vector<std::string>& path) ORTHANC_OVERRIDE; | |
48 | |
49 virtual bool ListCollection(Collection& collection, | |
50 const std::vector<std::string>& path) ORTHANC_OVERRIDE; | |
51 | |
52 virtual bool GetFileContent(MimeType& mime, | |
53 std::string& content, | |
54 boost::posix_time::ptime& modificationTime, | |
55 const std::vector<std::string>& path) ORTHANC_OVERRIDE; | |
56 | |
57 virtual bool StoreFile(const std::string& content, | |
58 const std::vector<std::string>& path) ORTHANC_OVERRIDE; | |
59 | |
60 virtual bool CreateFolder(const std::vector<std::string>& path) ORTHANC_OVERRIDE; | |
61 | |
4232
688435755466
added DELETE in WebDAV, first working virtual filesystem
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
4230
diff
changeset
|
62 virtual bool DeleteItem(const std::vector<std::string>& path) ORTHANC_OVERRIDE; |
688435755466
added DELETE in WebDAV, first working virtual filesystem
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
4230
diff
changeset
|
63 |
4230 | 64 virtual void Start() ORTHANC_OVERRIDE |
65 { | |
66 } | |
67 | |
68 virtual void Stop() ORTHANC_OVERRIDE | |
69 { | |
70 } | |
4239
c8754c4c1862
upload DICOM using WebDAV
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
4232
diff
changeset
|
71 |
c8754c4c1862
upload DICOM using WebDAV
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
4232
diff
changeset
|
72 void RemoveEmptyFolders(); |
4230 | 73 }; |
74 } |