Mercurial > hg > orthanc
diff OrthancServer/Database/SQLiteDatabaseWrapper.h @ 3187:4bbadcd03966
refactoring retrieval of metadata from database
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Mon, 04 Feb 2019 12:06:19 +0100 |
parents | c0d7aee8c3f8 |
children | 94f4a18a79cc |
line wrap: on
line diff
--- a/OrthancServer/Database/SQLiteDatabaseWrapper.h Fri Feb 01 09:28:12 2019 +0100 +++ b/OrthancServer/Database/SQLiteDatabaseWrapper.h Mon Feb 04 12:06:19 2019 +0100 @@ -38,6 +38,7 @@ #include "../../Core/SQLite/Connection.h" #include "Compatibility/ICreateInstance.h" #include "Compatibility/IGetChildrenMetadata.h" +#include "Compatibility/ILookupResourceAndParent.h" #include "Compatibility/ISetResourcesContent.h" namespace Orthanc @@ -56,6 +57,7 @@ public IDatabaseWrapper, public Compatibility::ICreateInstance, public Compatibility::IGetChildrenMetadata, + public Compatibility::ILookupResourceAndParent, public Compatibility::ISetResourcesContent { private: @@ -224,10 +226,6 @@ MetadataType type) ORTHANC_OVERRIDE; - virtual void ListAvailableMetadata(std::list<MetadataType>& target, - int64_t id) - ORTHANC_OVERRIDE; - virtual void AddAttachment(int64_t id, const FileInfo& attachment) ORTHANC_OVERRIDE; @@ -361,5 +359,14 @@ virtual int64_t GetLastChangeIndex() ORTHANC_OVERRIDE; virtual void TagMostRecentPatient(int64_t patient) ORTHANC_OVERRIDE; + + virtual bool LookupResourceAndParent(int64_t& id, + ResourceType& type, + std::string& parentPublicId, + const std::string& publicId) + ORTHANC_OVERRIDE + { + return ILookupResourceAndParent::Apply(*this, id, type, parentPublicId, publicId); + } }; }