Removed old Keep-Alive functions

This commit is contained in:
yhirose 2020-08-03 17:03:00 -04:00
parent abaf875c42
commit 38a7706c8b

View file

@ -1097,51 +1097,6 @@ private:
#endif
}; // namespace httplib
inline void Get(std::vector<Request> &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<Request> &requests, const char *path) {
Get(requests, path, Headers());
}
inline void Post(std::vector<Request> &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<Request> &requests, const char *path,
const std::string &body, const char *content_type) {
Post(requests, path, Headers(), body, content_type);
}
inline void Post(std::vector<Request> &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: