diff OrthancServer/main.cpp @ 1124:790ff7a5b3bf

IStorageArea abstraction
author Sebastien Jodogne <s.jodogne@gmail.com>
date Fri, 05 Sep 2014 16:28:34 +0200
parents da56a7916e8a
children f4e65808ea58
line wrap: on
line diff
--- a/OrthancServer/main.cpp	Fri Sep 05 15:59:04 2014 +0200
+++ b/OrthancServer/main.cpp	Fri Sep 05 16:28:34 2014 +0200
@@ -37,6 +37,7 @@
 #include <glog/logging.h>
 #include <boost/algorithm/string/predicate.hpp>
 
+#include "../Core/FileStorage/FilesystemStorage.h"
 #include "../Core/HttpServer/EmbeddedResourceHttpHandler.h"
 #include "../Core/HttpServer/FilesystemHttpHandler.h"
 #include "../Core/Lua/LuaFunctionCall.h"
@@ -320,7 +321,9 @@
   boost::filesystem::path storageDirectory = Configuration::InterpretStringParameterAsPath(storageDirectoryStr);
   boost::filesystem::path indexDirectory = Configuration::InterpretStringParameterAsPath(
     Configuration::GetGlobalStringParameter("IndexDirectory", storageDirectoryStr));
-  ServerContext context(storageDirectory, indexDirectory);
+
+  FilesystemStorage storage(storageDirectory.string());
+  ServerContext context(storage, indexDirectory);
 
   LOG(WARNING) << "Storage directory: " << storageDirectory;
   LOG(WARNING) << "Index directory: " << indexDirectory;