staticlib_http  1.3.2
 All Classes Namespaces Files Functions Variables
Public Attributes | List of all members
staticlib::http::request_options Struct Reference

Configuration options for the HTTP request. More...

#include <staticlib/http/request_options.hpp>

Public Attributes

std::vector< std::pair
< std::string, std::string > > 
headers
 Headers to send with a request.
std::string method = ""
 HTTP method to use.
bool abort_on_connect_error = true
 HttpException will be thrown from read method on unsuccessful connection attempt, see also 'connecttimeout_millis'.
bool abort_on_response_error = true
 HttpException will be thrown from read method on HTTP response code >= 400.
uint16_t max_number_of_response_headers = 128
 Max allowed number of response headers.
uint16_t consumer_thread_wakeup_timeout_millis = 100
 Consumer thread wakeup timeout (in milliseconds)
bool send_request_body_content_length = false
 Whether to specify a "Content-Length" header for the request body, not specified by default, "Transfer-Encoding: chunked" is used instead.
uint32_t request_body_content_length = 0
 "Content-Length" header value for request body, used only if "send_request_body_content_length" is enabled
bool force_http_10 = false
 https://curl.haxx.se/libcurl/c/CURLOPT_HTTP_VERSION.html
bool noprogress = true
 https://curl.haxx.se/libcurl/c/CURLOPT_NOPROGRESS.html
bool nosignal = true
 https://curl.haxx.se/libcurl/c/CURLOPT_NOSIGNAL.html
bool failonerror = false
 https://curl.haxx.se/libcurl/c/CURLOPT_FAILONERROR.html
bool path_as_is = true
 https://curl.haxx.se/libcurl/c/CURLOPT_PATH_AS_IS.html
bool tcp_nodelay = false
 https://curl.haxx.se/libcurl/c/CURLOPT_TCP_NODELAY.html
bool tcp_keepalive = false
 https://curl.haxx.se/libcurl/c/CURLOPT_TCP_KEEPALIVE.html
uint32_t tcp_keepidle_secs = 300
 https://curl.haxx.se/libcurl/c/CURLOPT_TCP_KEEPIDLE.html
uint32_t tcp_keepintvl_secs = 300
 https://curl.haxx.se/libcurl/c/CURLOPT_TCP_KEEPINTVL.html
uint32_t connecttimeout_millis = 10000
 https://curl.haxx.se/libcurl/c/CURLOPT_CONNECTTIMEOUT_MS.html
uint32_t timeout_millis = 15000
 https://curl.haxx.se/libcurl/c/CURLOPT_TIMEOUT_MS.html
uint32_t buffersize_bytes = 16384
 https://curl.haxx.se/libcurl/c/CURLOPT_BUFFERSIZE.html
std::string accept_encoding = "gzip"
 https://curl.haxx.se/libcurl/c/CURLOPT_ACCEPT_ENCODING.html
bool followlocation = true
 https://curl.haxx.se/libcurl/c/CURLOPT_FOLLOWLOCATION.html
uint32_t maxredirs = 32
 https://curl.haxx.se/libcurl/c/CURLOPT_MAXREDIRS.html
std::string useragent = ""
 https://curl.haxx.se/libcurl/c/CURLOPT_USERAGENT.html
uint32_t max_sent_speed_large_bytes_per_second = 0
 https://curl.haxx.se/libcurl/c/CURLOPT_MAX_SEND_SPEED_LARGE.html
uint32_t max_recv_speed_large_bytes_per_second = 0
 https://curl.haxx.se/libcurl/c/CURLOPT_MAX_RECV_SPEED_LARGE.html
std::string sslcert_filename = ""
 https://curl.haxx.se/libcurl/c/CURLOPT_SSLCERT.html
std::string sslcertype = ""
 https://curl.haxx.se/libcurl/c/CURLOPT_SSLCERTTYPE.html
std::string sslkey_filename = ""
 https://curl.haxx.se/libcurl/c/CURLOPT_SSLKEY.html
std::string ssl_key_type = ""
 https://curl.haxx.se/libcurl/c/CURLOPT_SSLKEYTYPE.html
std::string ssl_keypasswd = ""
 https://curl.haxx.se/libcurl/c/CURLOPT_KEYPASSWD.html
bool require_tls = false
 https://curl.haxx.se/libcurl/c/CURLOPT_SSLVERSION.html
bool ssl_verifyhost = false
 https://curl.haxx.se/libcurl/c/CURLOPT_SSL_VERIFYHOST.html
bool ssl_verifypeer = false
 https://curl.haxx.se/libcurl/c/CURLOPT_SSL_VERIFYPEER.html
bool ssl_verifystatus = false
 https://curl.haxx.se/libcurl/c/CURLOPT_SSL_VERIFYSTATUS.html
std::string cainfo_filename = ""
 https://curl.haxx.se/libcurl/c/CURLOPT_CAINFO.html
std::string crlfile_filename = ""
 https://curl.haxx.se/libcurl/c/CURLOPT_CRLFILE.html
std::string ssl_cipher_list = ""
 https://curl.haxx.se/libcurl/c/CURLOPT_SSL_CIPHER_LIST.html

Detailed Description

Configuration options for the HTTP request.

Member Data Documentation

bool staticlib::http::request_options::abort_on_connect_error = true

HttpException will be thrown from read method on unsuccessful connection attempt, see also 'connecttimeout_millis'.

bool staticlib::http::request_options::abort_on_response_error = true

HttpException will be thrown from read method on HTTP response code >= 400.

std::string staticlib::http::request_options::accept_encoding = "gzip"
uint32_t staticlib::http::request_options::buffersize_bytes = 16384
std::string staticlib::http::request_options::cainfo_filename = ""
uint32_t staticlib::http::request_options::connecttimeout_millis = 10000
uint16_t staticlib::http::request_options::consumer_thread_wakeup_timeout_millis = 100

Consumer thread wakeup timeout (in milliseconds)

std::string staticlib::http::request_options::crlfile_filename = ""
bool staticlib::http::request_options::failonerror = false
bool staticlib::http::request_options::followlocation = true
bool staticlib::http::request_options::force_http_10 = false
std::vector<std::pair<std::string, std::string> > staticlib::http::request_options::headers

Headers to send with a request.

uint16_t staticlib::http::request_options::max_number_of_response_headers = 128

Max allowed number of response headers.

uint32_t staticlib::http::request_options::max_recv_speed_large_bytes_per_second = 0
uint32_t staticlib::http::request_options::max_sent_speed_large_bytes_per_second = 0
uint32_t staticlib::http::request_options::maxredirs = 32
std::string staticlib::http::request_options::method = ""

HTTP method to use.

bool staticlib::http::request_options::noprogress = true
bool staticlib::http::request_options::nosignal = true
bool staticlib::http::request_options::path_as_is = true
uint32_t staticlib::http::request_options::request_body_content_length = 0

"Content-Length" header value for request body, used only if "send_request_body_content_length" is enabled

bool staticlib::http::request_options::require_tls = false
bool staticlib::http::request_options::send_request_body_content_length = false

Whether to specify a "Content-Length" header for the request body, not specified by default, "Transfer-Encoding: chunked" is used instead.

If set to "true", then client must also specify a "request_body_content_length" parameter

std::string staticlib::http::request_options::ssl_cipher_list = ""
std::string staticlib::http::request_options::ssl_key_type = ""
std::string staticlib::http::request_options::ssl_keypasswd = ""
bool staticlib::http::request_options::ssl_verifyhost = false
bool staticlib::http::request_options::ssl_verifypeer = false
bool staticlib::http::request_options::ssl_verifystatus = false
std::string staticlib::http::request_options::sslcert_filename = ""
std::string staticlib::http::request_options::sslcertype = ""
std::string staticlib::http::request_options::sslkey_filename = ""
bool staticlib::http::request_options::tcp_keepalive = false
uint32_t staticlib::http::request_options::tcp_keepidle_secs = 300
uint32_t staticlib::http::request_options::tcp_keepintvl_secs = 300
bool staticlib::http::request_options::tcp_nodelay = false
uint32_t staticlib::http::request_options::timeout_millis = 15000
std::string staticlib::http::request_options::useragent = ""

The documentation for this struct was generated from the following file: