AWS SDK for C++

AWS SDK for C++ Version 1.11.440

Loading...
Searching...
No Matches
StandardHttpResponse.h
1
6#pragma once
7
8#include <aws/core/Core_EXPORTS.h>
9
10#include <aws/core/http/HttpResponse.h>
11#include <aws/core/utils/memory/stl/AWSMap.h>
12#include <aws/core/utils/stream/ResponseStream.h>
13#include <aws/core/utils/memory/stl/AWSString.h>
14
15namespace Aws
16{
17 namespace Http
18 {
19 namespace Standard
20 {
24 class AWS_CORE_API StandardHttpResponse : public HttpResponse
25 {
26 public:
30 StandardHttpResponse(const std::shared_ptr<const HttpRequest>& originatingRequest) :
31 HttpResponse(originatingRequest),
32 bodyStream(originatingRequest->GetResponseStreamFactory())
33 {}
34
36
44 bool HasHeader(const char* headerName) const override;
48 const Aws::String& GetHeader(const Aws::String&) const override;
52 inline Aws::IOStream& GetResponseBody() const override { return bodyStream.GetUnderlyingStream(); }
57 inline Utils::Stream::ResponseStream&& SwapResponseStreamOwnership() override { return std::move(bodyStream); }
61 void AddHeader(const Aws::String&, const Aws::String&) override;
66 void AddHeader(const Aws::String& headerName, Aws::String&& headerValue) override;
67
68 private:
70
73 };
74
75 } // namespace Standard
76 } // namespace Http
77} // namespace Aws
78
79
void AddHeader(const Aws::String &, const Aws::String &) override
const Aws::String & GetHeader(const Aws::String &) const override
StandardHttpResponse(const std::shared_ptr< const HttpRequest > &originatingRequest)
HeaderValueCollection GetHeaders() const override
Aws::IOStream & GetResponseBody() const override
Utils::Stream::ResponseStream && SwapResponseStreamOwnership() override
bool HasHeader(const char *headerName) const override
void AddHeader(const Aws::String &headerName, Aws::String &&headerValue) override
Aws::Map< Aws::String, Aws::String > HeaderValueCollection
Definition HttpTypes.h:62
std::map< K, V, std::less< K >, Aws::Allocator< std::pair< const K, V > > > Map
Definition AWSMap.h:20
std::basic_iostream< char, std::char_traits< char > > IOStream
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Definition AWSString.h:97