azure-core
Loading...
Searching...
No Matches
response.hpp
Go to the documentation of this file.
1// Copyright (c) Microsoft Corporation.
2// Licensed under the MIT License.
3
10#pragma once
11
14
15#include <memory> // for unique_ptr
16#include <stdexcept>
17#include <utility> // for move
18
19namespace Azure {
26template <class T> class Response final {
27
28public:
32 std::unique_ptr<Azure::Core::Http::RawResponse> RawResponse;
33
40 explicit Response(T value, std::unique_ptr<Azure::Core::Http::RawResponse> rawResponse)
41 : Value(std::move(value)), RawResponse(std::move(rawResponse))
42 {
43 }
44};
45
46} // namespace Azure
Represents the result of an Azure operation over HTTP by wrapping the raw HTTP response from a reques...
Definition response.hpp:26
Response(T value, std::unique_ptr< Azure::Core::Http::RawResponse > rawResponse)
Constructs a Response with the value and raw response returned by the service.
Definition response.hpp:40
T Value
The value returned by the service.
Definition response.hpp:30
std::unique_ptr< Azure::Core::Http::RawResponse > RawResponse
The HTTP response returned by the service.
Definition response.hpp:32
HTTP request and response functionality.
Compute the hash value for the input binary data, using SHA256, SHA384 and SHA512.
Definition azure_assert.hpp:57
Manages an optional contained value, i.e. a value that may or may not be present.