Function head

Synopsis

#include <include/restclient-cpp/restclient.h>

Response head(const std::string &url)

Description

HTTP HEAD method.

Parameters

url - to query

Returns
response struct

Mentioned in

Source

Lines 163-174 in source/restclient.cc. Line 63 in include/restclient-cpp/restclient.h.

RestClient::Response RestClient::head(const std::string& url) {
#if __cplusplus >= 201402L
  auto conn = std::make_unique<RestClient::Connection>("");
  return conn->head(url);
#else
  RestClient::Response ret;
  RestClient::Connection *conn = new RestClient::Connection("");
  ret = conn->head(url);
  delete conn;
  return ret;
#endif
}





Add Discussion as Guest

Log in