diff OrthancFramework/Sources/HttpServer/IHttpHandler.h @ 4329:9dc0e42f868b

moving static methods from HttpToolbox to IHttpHandler
author Sebastien Jodogne <s.jodogne@gmail.com>
date Wed, 25 Nov 2020 13:46:49 +0100
parents bf7b9edf6b81
children a01b1c9cbef4
line wrap: on
line diff
--- a/OrthancFramework/Sources/HttpServer/IHttpHandler.h	Wed Nov 25 13:34:58 2020 +0100
+++ b/OrthancFramework/Sources/HttpServer/IHttpHandler.h	Wed Nov 25 13:46:49 2020 +0100
@@ -81,5 +81,32 @@
                         const GetArguments& getArguments,
                         const void* bodyData,
                         size_t bodySize) = 0;
+
+    static bool SimpleGet(std::string& result,
+                          IHttpHandler& handler,
+                          RequestOrigin origin,
+                          const std::string& uri,
+                          const Arguments& httpHeaders);
+
+    static bool SimplePost(std::string& result,
+                           IHttpHandler& handler,
+                           RequestOrigin origin,
+                           const std::string& uri,
+                           const void* bodyData,
+                           size_t bodySize,
+                           const Arguments& httpHeaders);
+
+    static bool SimplePut(std::string& result,
+                          IHttpHandler& handler,
+                          RequestOrigin origin,
+                          const std::string& uri,
+                          const void* bodyData,
+                          size_t bodySize,
+                          const Arguments& httpHeaders);
+
+    static bool SimpleDelete(IHttpHandler& handler,
+                             RequestOrigin origin,
+                             const std::string& uri,
+                             const Arguments& httpHeaders);
   };
 }