azure-core
Loading...
Searching...
No Matches
client_options.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>
16#include <vector>
17
18namespace Azure { namespace Core { namespace _internal {
19
24 struct ClientOptions
25 {
30 virtual ~ClientOptions() = default;
31
36 std::vector<std::unique_ptr<Azure::Core::Http::Policies::HttpPolicy>> PerOperationPolicies;
37
42 std::vector<std::unique_ptr<Azure::Core::Http::Policies::HttpPolicy>> PerRetryPolicies;
43
48 ClientOptions(ClientOptions&&) = default;
49
54 ClientOptions(ClientOptions const& other) { *this = other; }
55
56 ClientOptions() = default;
57
62 ClientOptions& operator=(ClientOptions&&) = default;
63
68 ClientOptions& operator=(const ClientOptions& other)
69 {
70 this->Retry = other.Retry;
71 this->Transport = other.Transport;
72 this->Telemetry = other.Telemetry;
73 this->Log = other.Log;
74 this->PerOperationPolicies.reserve(other.PerOperationPolicies.size());
75 for (auto& policy : other.PerOperationPolicies)
76 {
77 this->PerOperationPolicies.emplace_back(policy->Clone());
78 }
79 this->PerRetryPolicies.reserve(other.PerRetryPolicies.size());
80 for (auto& policy : other.PerRetryPolicies)
81 {
82 this->PerRetryPolicies.emplace_back(policy->Clone());
83 }
84 return *this;
85 }
86
92
98
104
110 };
111
112}}} // namespace Azure::Core::_internal
HTTP request and response functionality.
Compute the hash value for the input binary data, using SHA256, SHA384 and SHA512.
Definition azure_assert.hpp:57
HTTP transport policies, and their options.
Log options that parameterize the information being logged.
Definition policy.hpp:144
The set of options that can be specified to influence how retry attempts are made,...
Definition policy.hpp:104
Telemetry options, used to configure telemetry parameters.
Definition policy.hpp:61
HTTP transport options parameterize the HTTP transport adapter being used.
Definition policy.hpp:162