Mercurial > hg > orthanc-databases
comparison Framework/Plugins/IndexUnitTests.h @ 309:d192bfd0e752
tagging globalParameters_ as static in MySQL
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Mon, 12 Jul 2021 18:45:09 +0200 |
parents | 8de3a1ecac11 |
children | 5f0d5f849944 |
comparison
equal
deleted
inserted
replaced
308:6a668f5d1069 | 309:d192bfd0e752 |
---|---|
42 # define HAS_REVISIONS 1 | 42 # define HAS_REVISIONS 1 |
43 #elif ORTHANC_ENABLE_MYSQL == 1 | 43 #elif ORTHANC_ENABLE_MYSQL == 1 |
44 # define HAS_REVISIONS 0 | 44 # define HAS_REVISIONS 0 |
45 #elif ORTHANC_ENABLE_SQLITE == 1 | 45 #elif ORTHANC_ENABLE_SQLITE == 1 |
46 # define HAS_REVISIONS 1 | 46 # define HAS_REVISIONS 1 |
47 #elif ORTHANC_ENABLE_ODBC == 1 | |
48 # define HAS_REVISIONS 1 | |
47 #else | 49 #else |
48 # error Unknown database backend | 50 # error Unknown database backend |
49 #endif | 51 #endif |
50 | 52 |
51 | 53 |
208 #elif ORTHANC_ENABLE_MYSQL == 1 | 210 #elif ORTHANC_ENABLE_MYSQL == 1 |
209 MySQLIndex db(&context, globalParameters_); | 211 MySQLIndex db(&context, globalParameters_); |
210 db.SetClearAll(true); | 212 db.SetClearAll(true); |
211 #elif ORTHANC_ENABLE_SQLITE == 1 | 213 #elif ORTHANC_ENABLE_SQLITE == 1 |
212 SQLiteIndex db(&context); // Open in memory | 214 SQLiteIndex db(&context); // Open in memory |
215 #elif ORTHANC_ENABLE_ODBC == 1 | |
216 OdbcIndex db(&context, connectionString_); | |
213 #else | 217 #else |
214 # error Unsupported database backend | 218 # error Unsupported database backend |
215 #endif | 219 #endif |
216 | 220 |
217 db.SetOutputFactory(new DatabaseBackendAdapterV2::Factory(&context, NULL)); | 221 db.SetOutputFactory(new DatabaseBackendAdapterV2::Factory(&context, NULL)); |