From 38a7706c8bf2d3a8d308068e42658f876b9c5bf3 Mon Sep 17 00:00:00 2001 From: yhirose Date: Mon, 3 Aug 2020 17:03:00 -0400 Subject: [PATCH] Removed old Keep-Alive functions --- httplib.h | 45 --------------------------------------------- 1 file changed, 45 deletions(-) diff --git a/httplib.h b/httplib.h index 95659aa..1016915 100644 --- a/httplib.h +++ b/httplib.h @@ -1097,51 +1097,6 @@ private: #endif }; // namespace httplib -inline void Get(std::vector &requests, const char *path, - const Headers &headers) { - Request req; - req.method = "GET"; - req.path = path; - req.headers = headers; - requests.emplace_back(std::move(req)); -} - -inline void Get(std::vector &requests, const char *path) { - Get(requests, path, Headers()); -} - -inline void Post(std::vector &requests, const char *path, - const Headers &headers, const std::string &body, - const char *content_type) { - Request req; - req.method = "POST"; - req.path = path; - req.headers = headers; - if (content_type) { req.headers.emplace("Content-Type", content_type); } - req.body = body; - requests.emplace_back(std::move(req)); -} - -inline void Post(std::vector &requests, const char *path, - const std::string &body, const char *content_type) { - Post(requests, path, Headers(), body, content_type); -} - -inline void Post(std::vector &requests, const char *path, - size_t content_length, ContentProvider content_provider, - const char *content_type) { - Request req; - req.method = "POST"; - req.headers = Headers(); - req.path = path; - req.content_length = content_length; - req.content_provider = content_provider; - - if (content_type) { req.headers.emplace("Content-Type", content_type); } - - requests.emplace_back(std::move(req)); -} - #ifdef CPPHTTPLIB_OPENSSL_SUPPORT class SSLServer : public Server { public: