diff Framework/Toolbox/OrthancApiClient.h @ 434:3a8bcc45c221 am-vsol-upgrade

moved the HTTP cache from OrthancApiClient to BaseWebService (not implemented yet in WASM)
author am@osimis.io
date Mon, 03 Dec 2018 18:03:30 +0100
parents bb573a52fc63
children a750f11892ec
line wrap: on
line diff
--- a/Framework/Toolbox/OrthancApiClient.h	Mon Dec 03 14:22:47 2018 +0100
+++ b/Framework/Toolbox/OrthancApiClient.h	Mon Dec 03 18:03:30 2018 +0100
@@ -149,14 +149,11 @@
 
   private:
     class WebServicePayload;
-    class CachedHttpRequestSuccessMessage;
 
   protected:
     IWebService&  web_;
     std::string   baseUrl_;
 
-    std::map<std::string, boost::shared_ptr<CachedHttpRequestSuccessMessage>> cache_;  // TODO: this is currently an infinite cache !
-    bool          cacheEnabled_;
   public:
     OrthancApiClient(MessageBroker& broker,
                      IWebService& web,
@@ -166,11 +163,6 @@
     {
     }
 
-    void EnableCache(bool enable)
-    {
-      cacheEnabled_ = enable;
-    }
-
     // schedule a GET request expecting a JSON response.
     void GetJsonAsync(const std::string& uri,
                       MessageHandler<JsonResponseReadyMessage>* successCallback,
@@ -223,8 +215,6 @@
 
     void NotifyHttpError(const IWebService::HttpRequestErrorMessage& message);
 
-    void CacheAndNotifyHttpSuccess(const IWebService::HttpRequestSuccessMessage& message);
-
   private:
     void HandleFromCache(const std::string& uri,
                          const IWebService::HttpHeaders& headers,