AWS SDK for C++
AWS SDK for C++
Loading...
Searching...
No Matches
CurlHttpClient.h
Go to the documentation of this file.
1
7#pragma once
8
14#include <atomic>
15
16namespace Aws
17{
18namespace Http
19{
20namespace Standard
21{
23}
24
25//Curl implementation of an http client. Right now it is only synchronous.
27{
28public:
29
31
32 //Creates client, initializes curl handle if it hasn't been created already.
34
35 //Makes request and receives response synchronously
36 std::shared_ptr<HttpResponse> MakeRequest(const std::shared_ptr<HttpRequest>& request,
38 Aws::Utils::RateLimits::RateLimiterInterface* writeLimiter = nullptr) const override;
39
40 static void InitGlobalState();
41 static void CleanupGlobalState();
42
43protected:
48 virtual void OverrideOptionsOnConnectionHandle(CURL*) const {}
49
50private:
51 mutable CurlHandleContainer m_curlHandleContainer;
52 bool m_isUsingProxy;
53 Aws::String m_proxyUserName;
54 Aws::String m_proxyPassword;
55 Aws::String m_proxyScheme;
56 Aws::String m_proxyHost;
57 Aws::String m_proxySSLCertPath;
58 Aws::String m_proxySSLCertType;
59 Aws::String m_proxySSLKeyPath;
60 Aws::String m_proxySSLKeyType;
61 Aws::String m_proxyKeyPasswd;
62 unsigned m_proxyPort;
63 Aws::String m_nonProxyHosts;
64 bool m_verifySSL;
65 Aws::String m_caPath;
66 Aws::String m_caFile;
67 bool m_disableExpectHeader;
68 bool m_allowRedirects;
69 static std::atomic<bool> isInit;
70};
71
73
74} // namespace Http
75} // namespace Aws
76
#define AWS_CORE_API
Definition: Core_EXPORTS.h:26
static void InitGlobalState()
virtual void OverrideOptionsOnConnectionHandle(CURL *) const
std::shared_ptr< HttpResponse > MakeRequest(const std::shared_ptr< HttpRequest > &request, Aws::Utils::RateLimits::RateLimiterInterface *readLimiter=nullptr, Aws::Utils::RateLimits::RateLimiterInterface *writeLimiter=nullptr) const override
static void CleanupGlobalState()
CurlHttpClient(const Aws::Client::ClientConfiguration &clientConfig)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Definition: AWSString.h:97