DotNetDupe 4.0.6
C++17/20 Implementation of the .NET Base Class Library (BCL)
Loading...
Searching...
No Matches
HttpResponseMessage.h
Go to the documentation of this file.
1
3
4#pragma once
5#include "Common.h"
6#include "System/Object.h"
7#include "System/String.h"
12
13namespace DotNetDupe {
14 namespace System {
15 namespace Net {
16 namespace Http {
17
78
81
82 }
83 }
84 }
85}
Defines common cross-platform macros, export decorators, and fundamental types.
#define DOTNETDUPE_API
Platform-specific linkage decoration for exporting or importing library symbols.
Definition Common.h:20
Represents an HTTP entity body and associated content headers.
Defines HTTP status codes defined for HTTP/1.1 and HTTP/2.
Base object class for DotNetDupe mirroring .NET System.Object.
Provides reference-counted and weak pointer memory management primitives ensuring zero raw ownership.
High-performance UTF-8 / UTF-16 string manipulation class mirroring .NET System.String.
Represents a collection of keys and values.
Definition Dictionary.h:66
void SetContent(const HttpContentPtr &content)
Sets the content of the HTTP response message.
HttpStatusCode GetStatusCode() const
Gets the status code of the HTTP response.
String GetReasonPhrase() const
Gets the reason phrase which typically accompanies the status code.
void SetReasonPhrase(const String &reasonPhrase)
Sets the reason phrase which typically accompanies the status code.
void EnsureSuccessStatusCode()
Throws an HttpRequestException if IsSuccessStatusCode() is false.
void SetStatusCode(HttpStatusCode statusCode)
Sets the status code of the HTTP response.
HttpContentPtr GetContent() const
Gets the content of the HTTP response message.
bool IsSuccessStatusCode() const
Gets a value that indicates if the HTTP response was successful (status in range 200-299).
HttpResponseMessage()
Initializes a new instance of the HttpResponseMessage class with OK (200) status.
Collections::Generic::Dictionary< String, String > & GetHeaders()
Gets the collection of HTTP response headers.
Supports all classes in the DotNetDupe class hierarchy.
Definition Object.h:18
A unified smart pointer that supports both unique and shared ownership semantics.
Represents text as a sequence of UTF-8 code units with culture-invariant operations.
Definition String.h:74
SmartPointer< HttpResponseMessage > HttpResponseMessagePtr
Type alias for reference-counted SmartPointer to HttpResponseMessage.
SmartPointer< HttpContent > HttpContentPtr
Type alias for reference-counted SmartPointer to HttpContent.
Definition HttpContent.h:66
HttpStatusCode
Contains the values of status codes defined for HTTP in RFC 9110 and RFC 7231.