comparison OrthancServer/SQLiteDatabaseWrapper.h @ 3091:476cba12c2b0 db-changes

IDatabaseWrapper::GetChildrenMetadata()
author Sebastien Jodogne <s.jodogne@gmail.com>
date Sat, 05 Jan 2019 15:08:53 +0100
parents 195ba4cbac3f
children
comparison
equal deleted inserted replaced
3090:31244604f617 3091:476cba12c2b0
35 35
36 #include "IDatabaseWrapper.h" 36 #include "IDatabaseWrapper.h"
37 37
38 #include "../Core/SQLite/Connection.h" 38 #include "../Core/SQLite/Connection.h"
39 #include "Search/Compatibility/ICreateInstance.h" 39 #include "Search/Compatibility/ICreateInstance.h"
40 #include "Search/Compatibility/IGetChildrenMetadata.h"
40 #include "Search/Compatibility/ISetResourcesContent.h" 41 #include "Search/Compatibility/ISetResourcesContent.h"
41 #include "ServerToolbox.h" 42 #include "ServerToolbox.h"
42 43
43 namespace Orthanc 44 namespace Orthanc
44 { 45 {
53 * exclusion MUST be implemented at a higher level. 54 * exclusion MUST be implemented at a higher level.
54 **/ 55 **/
55 class SQLiteDatabaseWrapper : 56 class SQLiteDatabaseWrapper :
56 public IDatabaseWrapper, 57 public IDatabaseWrapper,
57 public Compatibility::ICreateInstance, 58 public Compatibility::ICreateInstance,
59 public Compatibility::IGetChildrenMetadata,
58 public Compatibility::ISetResourcesContent 60 public Compatibility::ISetResourcesContent
59 { 61 {
60 private: 62 private:
61 class Transaction; 63 class Transaction;
62 class LookupFormatter; 64 class LookupFormatter;
330 virtual bool CreateInstance(CreateInstanceResult& result, 332 virtual bool CreateInstance(CreateInstanceResult& result,
331 int64_t& instanceId, 333 int64_t& instanceId,
332 const std::string& patient, 334 const std::string& patient,
333 const std::string& study, 335 const std::string& study,
334 const std::string& series, 336 const std::string& series,
335 const std::string& instance) ORTHANC_OVERRIDE 337 const std::string& instance)
338 ORTHANC_OVERRIDE
336 { 339 {
337 return ICreateInstance::Apply 340 return ICreateInstance::Apply
338 (*this, *this, result, instanceId, patient, study, series, instance); 341 (*this, result, instanceId, patient, study, series, instance);
339 } 342 }
340 343
341 virtual void SetResourcesContent(const Orthanc::ResourcesContent& content) ORTHANC_OVERRIDE 344 virtual void SetResourcesContent(const Orthanc::ResourcesContent& content)
345 ORTHANC_OVERRIDE
342 { 346 {
343 ISetResourcesContent::Apply(*this, content); 347 ISetResourcesContent::Apply(*this, content);
348 }
349
350 virtual void GetChildrenMetadata(std::list<std::string>& target,
351 int64_t resourceId,
352 MetadataType metadata)
353 ORTHANC_OVERRIDE
354 {
355 IGetChildrenMetadata::Apply(*this, target, resourceId, metadata);
344 } 356 }
345 }; 357 };
346 } 358 }