AWS SDK for C++

AWS SDK for C++ Version 1.11.719

Loading...
Searching...
No Matches
CreatePlaybackRestrictionPolicyRequest.h
1
6#pragma once
7#include <aws/core/utils/memory/stl/AWSMap.h>
8#include <aws/core/utils/memory/stl/AWSString.h>
9#include <aws/core/utils/memory/stl/AWSVector.h>
10#include <aws/ivs/IVSRequest.h>
11#include <aws/ivs/IVS_EXPORTS.h>
12
13#include <utility>
14
15namespace Aws {
16namespace IVS {
17namespace Model {
18
22 public:
24
25 // Service request name is the Operation name which will send this request out,
26 // each operation should has unique request name, so that we can get operation's name from this request.
27 // Note: this is not true for response, multiple operations may have the same response name,
28 // so we can not get operation's name from response.
29 inline virtual const char* GetServiceRequestName() const override { return "CreatePlaybackRestrictionPolicy"; }
30
31 AWS_IVS_API Aws::String SerializePayload() const override;
32
34
40 inline const Aws::Vector<Aws::String>& GetAllowedCountries() const { return m_allowedCountries; }
41 inline bool AllowedCountriesHasBeenSet() const { return m_allowedCountriesHasBeenSet; }
42 template <typename AllowedCountriesT = Aws::Vector<Aws::String>>
43 void SetAllowedCountries(AllowedCountriesT&& value) {
44 m_allowedCountriesHasBeenSet = true;
45 m_allowedCountries = std::forward<AllowedCountriesT>(value);
46 }
47 template <typename AllowedCountriesT = Aws::Vector<Aws::String>>
49 SetAllowedCountries(std::forward<AllowedCountriesT>(value));
50 return *this;
51 }
52 template <typename AllowedCountriesT = Aws::String>
54 m_allowedCountriesHasBeenSet = true;
55 m_allowedCountries.emplace_back(std::forward<AllowedCountriesT>(value));
56 return *this;
57 }
59
61
67 inline const Aws::Vector<Aws::String>& GetAllowedOrigins() const { return m_allowedOrigins; }
68 inline bool AllowedOriginsHasBeenSet() const { return m_allowedOriginsHasBeenSet; }
69 template <typename AllowedOriginsT = Aws::Vector<Aws::String>>
70 void SetAllowedOrigins(AllowedOriginsT&& value) {
71 m_allowedOriginsHasBeenSet = true;
72 m_allowedOrigins = std::forward<AllowedOriginsT>(value);
73 }
74 template <typename AllowedOriginsT = Aws::Vector<Aws::String>>
76 SetAllowedOrigins(std::forward<AllowedOriginsT>(value));
77 return *this;
78 }
79 template <typename AllowedOriginsT = Aws::String>
81 m_allowedOriginsHasBeenSet = true;
82 m_allowedOrigins.emplace_back(std::forward<AllowedOriginsT>(value));
83 return *this;
84 }
86
88
92 inline bool GetEnableStrictOriginEnforcement() const { return m_enableStrictOriginEnforcement; }
93 inline bool EnableStrictOriginEnforcementHasBeenSet() const { return m_enableStrictOriginEnforcementHasBeenSet; }
94 inline void SetEnableStrictOriginEnforcement(bool value) {
95 m_enableStrictOriginEnforcementHasBeenSet = true;
96 m_enableStrictOriginEnforcement = value;
97 }
100 return *this;
101 }
103
105
108 inline const Aws::String& GetName() const { return m_name; }
109 inline bool NameHasBeenSet() const { return m_nameHasBeenSet; }
110 template <typename NameT = Aws::String>
111 void SetName(NameT&& value) {
112 m_nameHasBeenSet = true;
113 m_name = std::forward<NameT>(value);
114 }
115 template <typename NameT = Aws::String>
117 SetName(std::forward<NameT>(value));
118 return *this;
119 }
121
123
132 inline const Aws::Map<Aws::String, Aws::String>& GetTags() const { return m_tags; }
133 inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; }
134 template <typename TagsT = Aws::Map<Aws::String, Aws::String>>
135 void SetTags(TagsT&& value) {
136 m_tagsHasBeenSet = true;
137 m_tags = std::forward<TagsT>(value);
138 }
139 template <typename TagsT = Aws::Map<Aws::String, Aws::String>>
141 SetTags(std::forward<TagsT>(value));
142 return *this;
143 }
144 template <typename TagsKeyT = Aws::String, typename TagsValueT = Aws::String>
145 CreatePlaybackRestrictionPolicyRequest& AddTags(TagsKeyT&& key, TagsValueT&& value) {
146 m_tagsHasBeenSet = true;
147 m_tags.emplace(std::forward<TagsKeyT>(key), std::forward<TagsValueT>(value));
148 return *this;
149 }
151 private:
152 Aws::Vector<Aws::String> m_allowedCountries;
153
154 Aws::Vector<Aws::String> m_allowedOrigins;
155
156 bool m_enableStrictOriginEnforcement{false};
157
158 Aws::String m_name;
159
161 bool m_allowedCountriesHasBeenSet = false;
162 bool m_allowedOriginsHasBeenSet = false;
163 bool m_enableStrictOriginEnforcementHasBeenSet = false;
164 bool m_nameHasBeenSet = false;
165 bool m_tagsHasBeenSet = false;
166};
167
168} // namespace Model
169} // namespace IVS
170} // namespace Aws
AWS_IVS_API Aws::String SerializePayload() const override
CreatePlaybackRestrictionPolicyRequest & WithName(NameT &&value)
CreatePlaybackRestrictionPolicyRequest & WithAllowedOrigins(AllowedOriginsT &&value)
CreatePlaybackRestrictionPolicyRequest & WithAllowedCountries(AllowedCountriesT &&value)
CreatePlaybackRestrictionPolicyRequest & AddAllowedCountries(AllowedCountriesT &&value)
CreatePlaybackRestrictionPolicyRequest & AddTags(TagsKeyT &&key, TagsValueT &&value)
CreatePlaybackRestrictionPolicyRequest & WithTags(TagsT &&value)
CreatePlaybackRestrictionPolicyRequest & AddAllowedOrigins(AllowedOriginsT &&value)
CreatePlaybackRestrictionPolicyRequest & WithEnableStrictOriginEnforcement(bool value)
std::map< K, V, std::less< K >, Aws::Allocator< std::pair< const K, V > > > Map
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector