Mercurial > hg > orthanc-databases
annotate SQLite/Plugins/SQLiteIndex.h @ 297:86265ef5f3e3
fix
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Thu, 01 Jul 2021 11:31:16 +0200 |
parents | 793bbbe11287 |
children | 16aac0287485 cd9521e04249 |
rev | line source |
---|---|
0 | 1 /** |
2 * Orthanc - A Lightweight, RESTful DICOM Store | |
3 * Copyright (C) 2012-2016 Sebastien Jodogne, Medical Physics | |
4 * Department, University Hospital of Liege, Belgium | |
193
3236894320d6
upgrade to year 2021
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
142
diff
changeset
|
5 * Copyright (C) 2017-2021 Osimis S.A., Belgium |
0 | 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 "../../Framework/Plugins/IndexBackend.h" | |
25 | |
26 namespace OrthancDatabases | |
27 { | |
28 class SQLiteIndex : public IndexBackend | |
29 { | |
30 private: | |
228 | 31 std::string path_; |
32 bool fast_; | |
0 | 33 |
34 public: | |
252 | 35 explicit SQLiteIndex(OrthancPluginContext* context); // Opens in memory |
0 | 36 |
201
42990b2dd51b
create IDatabaseBackendOutput only if needed
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
199
diff
changeset
|
37 SQLiteIndex(OrthancPluginContext* context, |
42990b2dd51b
create IDatabaseBackendOutput only if needed
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
199
diff
changeset
|
38 const std::string& path); |
0 | 39 |
40 void SetFast(bool fast) | |
41 { | |
42 fast_ = fast; | |
43 } | |
44 | |
255
d663d9e44f8d
reintroduction of IDatabaseFactory into DatabaseManager
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
252
diff
changeset
|
45 virtual IDatabaseFactory* CreateDatabaseFactory() ORTHANC_OVERRIDE; |
226
a4918d57435c
DatabaseManager doesn't IDatabaseFactory anymore
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
225
diff
changeset
|
46 |
237
35598014f140
refactoring to remove GlobalProperties.cpp
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
228
diff
changeset
|
47 virtual void ConfigureDatabase(DatabaseManager& manager) ORTHANC_OVERRIDE; |
224
61c309e06797
added internal class DatabaseBackendAdapterV2::Adapter
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
201
diff
changeset
|
48 |
260
793bbbe11287
IDatabaseBackend::HasRevisionsSupport()
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
255
diff
changeset
|
49 virtual bool HasRevisionsSupport() const ORTHANC_OVERRIDE |
793bbbe11287
IDatabaseBackend::HasRevisionsSupport()
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
255
diff
changeset
|
50 { |
793bbbe11287
IDatabaseBackend::HasRevisionsSupport()
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
255
diff
changeset
|
51 return true; |
793bbbe11287
IDatabaseBackend::HasRevisionsSupport()
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
255
diff
changeset
|
52 } |
793bbbe11287
IDatabaseBackend::HasRevisionsSupport()
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
255
diff
changeset
|
53 |
225
94c9908e6aca
removed DatabaseManager member out of class IndexBackend
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
224
diff
changeset
|
54 virtual int64_t CreateResource(DatabaseManager& manager, |
94c9908e6aca
removed DatabaseManager member out of class IndexBackend
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
224
diff
changeset
|
55 const char* publicId, |
252 | 56 OrthancPluginResourceType type) ORTHANC_OVERRIDE; |
85
1012fe77241c
new extension implemented for PostgreSQL and SQLite: GetLastChangeIndex
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
67
diff
changeset
|
57 |
1012fe77241c
new extension implemented for PostgreSQL and SQLite: GetLastChangeIndex
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
67
diff
changeset
|
58 // New primitive since Orthanc 1.5.2 |
252 | 59 virtual int64_t GetLastChangeIndex(DatabaseManager& manager) ORTHANC_OVERRIDE; |
0 | 60 }; |
61 } |