AWS SDK for C++  0.14.3
AWS SDK for C++
Public Member Functions | List of all members
Aws::Http::HttpResponse Class Referenceabstract

#include <HttpResponse.h>

+ Inheritance diagram for Aws::Http::HttpResponse:

Public Member Functions

 HttpResponse (const HttpRequest &originatingRequest)
 
virtual ~HttpResponse ()=default
 
virtual const HttpRequestGetOriginatingRequest () const
 
virtual HeaderValueCollection GetHeaders () const =0
 
virtual bool HasHeader (const char *headerName) const =0
 
virtual const Aws::StringGetHeader (const Aws::String &headerName) const =0
 
virtual HttpResponseCode GetResponseCode () const
 
virtual void SetResponseCode (HttpResponseCode httpResponseCode)
 
virtual const Aws::StringGetContentType () const
 
virtual Aws::IOStreamGetResponseBody () const =0
 
virtual Utils::Stream::ResponseStream && SwapResponseStreamOwnership ()=0
 
virtual void AddHeader (const Aws::String &, const Aws::String &)=0
 
virtual void SetContentType (const Aws::String &contentType)
 

Detailed Description

Abstract class for representing an Http Response.

Definition at line 120 of file HttpResponse.h.

Constructor & Destructor Documentation

Aws::Http::HttpResponse::HttpResponse ( const HttpRequest originatingRequest)
inline

Initializes an http response with the originalRequest and the response code.

Definition at line 126 of file HttpResponse.h.

virtual Aws::Http::HttpResponse::~HttpResponse ( )
virtualdefault

Member Function Documentation

virtual void Aws::Http::HttpResponse::AddHeader ( const Aws::String ,
const Aws::String  
)
pure virtual

Adds a header to the http response object.

Implemented in Aws::Http::Standard::StandardHttpResponse.

virtual const Aws::String& Aws::Http::HttpResponse::GetContentType ( ) const
inlinevirtual

Gets the content-type of the response body

Definition at line 161 of file HttpResponse.h.

virtual const Aws::String& Aws::Http::HttpResponse::GetHeader ( const Aws::String headerName) const
pure virtual

Returns the value for a header at headerName if it exists.

Implemented in Aws::Http::Standard::StandardHttpResponse.

virtual HeaderValueCollection Aws::Http::HttpResponse::GetHeaders ( ) const
pure virtual

Get the headers from this response

Implemented in Aws::Http::Standard::StandardHttpResponse.

virtual const HttpRequest& Aws::Http::HttpResponse::GetOriginatingRequest ( ) const
inlinevirtual

Get the request that originated this response

Definition at line 136 of file HttpResponse.h.

virtual Aws::IOStream& Aws::Http::HttpResponse::GetResponseBody ( ) const
pure virtual

Gets the response body of the response.

Implemented in Aws::Http::Standard::StandardHttpResponse.

virtual HttpResponseCode Aws::Http::HttpResponse::GetResponseCode ( ) const
inlinevirtual

Gets response code for this http response.

Definition at line 153 of file HttpResponse.h.

virtual bool Aws::Http::HttpResponse::HasHeader ( const char *  headerName) const
pure virtual

Returns true if the response contains a header by headerName

Implemented in Aws::Http::Standard::StandardHttpResponse.

virtual void Aws::Http::HttpResponse::SetContentType ( const Aws::String contentType)
inlinevirtual

Sets the content type header on the http response object.

Definition at line 178 of file HttpResponse.h.

virtual void Aws::Http::HttpResponse::SetResponseCode ( HttpResponseCode  httpResponseCode)
inlinevirtual

Sets the response code for this http response.

Definition at line 157 of file HttpResponse.h.

virtual Utils::Stream::ResponseStream&& Aws::Http::HttpResponse::SwapResponseStreamOwnership ( )
pure virtual

Gives full control of the memory of the ResponseBody over to the caller. At this point, it is the caller's responsibility to clean up this object.

Implemented in Aws::Http::Standard::StandardHttpResponse.


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