Mercurial > hg > orthanc-webviewer
diff Plugin/Cache/CacheManager.h @ 147:70d1fe6d6309
Avoid hard crash if not enough memory
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Wed, 09 Nov 2016 12:43:58 +0100 |
parents | 3809121c3290 |
children | 5dc54316d68b |
line wrap: on
line diff
--- a/Plugin/Cache/CacheManager.h Wed Nov 09 12:20:01 2016 +0100 +++ b/Plugin/Cache/CacheManager.h Wed Nov 09 12:43:58 2016 +0100 @@ -23,6 +23,8 @@ #include "../../Orthanc/Core/SQLite/Connection.h" #include "../../Orthanc/Core/FileStorage/FilesystemStorage.h" +#include <orthanc/OrthancCPlugin.h> + namespace OrthancPlugins { enum CacheProperty @@ -69,9 +71,12 @@ public: - CacheManager(Orthanc::SQLite::Connection& db, + CacheManager(OrthancPluginContext* context, + Orthanc::SQLite::Connection& db, Orthanc::FilesystemStorage& storage); + OrthancPluginContext* GetPluginContext() const; + void SetSanityCheckEnabled(bool enabled); void Clear();