AWS SDK for C++  0.12.9
AWS SDK for C++
WinINetSyncHttpClient.h
Go to the documentation of this file.
1 /*
2  * Copyright 2010-2016 Amazon.com, Inc. or its affiliates. All Rights Reserved.
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License").
5  * You may not use this file except in compliance with the License.
6  * A copy of the License is located at
7  *
8  * http://aws.amazon.com/apache2.0
9  *
10  * or in the "license" file accompanying this file. This file is distributed
11  * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
12  * express or implied. See the License for the specific language governing
13  * permissions and limitations under the License.
14  */
15 
16 #pragma once
17 
18 #include <aws/core/Core_EXPORTS.h>
19 
22 
23 namespace Aws
24 {
25  namespace Client
26  {
27  struct ClientConfiguration;
28  } // namespace Client
29 
30  namespace Http
31  {
32  class WinINetConnectionPoolMgr;
33 
38  {
39  public:
41 
47 
51  const char* GetLogTag() const override { return "WinInetSyncHttpClient"; }
52  private:
53 
54  // WinHttp specific implementations
55  void* OpenRequest(const Aws::Http::HttpRequest& request, void* connection, const Aws::StringStream& ss) const override;
56  void DoAddHeaders(void* hHttpRequest, Aws::String& headerStr) const override;
57  uint64_t DoWriteData(void* hHttpRequest, char* streamBuffer, uint64_t bytesRead) const override;
58  bool DoReceiveResponse(void* hHttpRequest) const override;
59  bool DoQueryHeaders(void* hHttpRequest, std::shared_ptr<Aws::Http::Standard::StandardHttpResponse>& response, Aws::StringStream& ss, uint64_t& read) const override;
60  bool DoSendRequest(void* hHttpRequest) const override;
61  bool DoReadData(void* hHttpRequest, char* body, uint64_t size, uint64_t& read) const override;
62  void* GetClientModule() const override;
63 
64  WinINetSyncHttpClient &operator =(const WinINetSyncHttpClient &rhs);
65  };
66 
67  } // namespace Http
68 } // namespace Aws
69 
std::basic_stringstream< char, std::char_traits< char >, Aws::Allocator< char > > StringStream
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Definition: AWSString.h:97
#define AWS_CORE_API
Definition: Core_EXPORTS.h:30
JSON (JavaScript Object Notation).
const char * GetLogTag() const override