AWS SDK for C++

AWS SDK for C++ Version 1.11.743

Loading...
Searching...
No Matches
DefaultCacheBehavior.h
1
6#pragma once
7#include <aws/cloudfront/CloudFront_EXPORTS.h>
8#include <aws/cloudfront/model/AllowedMethods.h>
9#include <aws/cloudfront/model/FunctionAssociations.h>
10#include <aws/cloudfront/model/GrpcConfig.h>
11#include <aws/cloudfront/model/LambdaFunctionAssociations.h>
12#include <aws/cloudfront/model/TrustedKeyGroups.h>
13#include <aws/cloudfront/model/TrustedSigners.h>
14#include <aws/cloudfront/model/ViewerProtocolPolicy.h>
15#include <aws/core/utils/memory/stl/AWSString.h>
16
17#include <utility>
18
19namespace Aws {
20namespace Utils {
21namespace Xml {
22class XmlNode;
23} // namespace Xml
24} // namespace Utils
25namespace CloudFront {
26namespace Model {
27
42 public:
43 AWS_CLOUDFRONT_API DefaultCacheBehavior() = default;
44 AWS_CLOUDFRONT_API DefaultCacheBehavior(const Aws::Utils::Xml::XmlNode& xmlNode);
45 AWS_CLOUDFRONT_API DefaultCacheBehavior& operator=(const Aws::Utils::Xml::XmlNode& xmlNode);
46
47 AWS_CLOUDFRONT_API void AddToNode(Aws::Utils::Xml::XmlNode& parentNode) const;
48
50
54 inline const Aws::String& GetTargetOriginId() const { return m_targetOriginId; }
55 inline bool TargetOriginIdHasBeenSet() const { return m_targetOriginIdHasBeenSet; }
56 template <typename TargetOriginIdT = Aws::String>
57 void SetTargetOriginId(TargetOriginIdT&& value) {
58 m_targetOriginIdHasBeenSet = true;
59 m_targetOriginId = std::forward<TargetOriginIdT>(value);
60 }
61 template <typename TargetOriginIdT = Aws::String>
62 DefaultCacheBehavior& WithTargetOriginId(TargetOriginIdT&& value) {
63 SetTargetOriginId(std::forward<TargetOriginIdT>(value));
64 return *this;
65 }
67
69
87 inline const TrustedSigners& GetTrustedSigners() const { return m_trustedSigners; }
88 inline bool TrustedSignersHasBeenSet() const { return m_trustedSignersHasBeenSet; }
89 template <typename TrustedSignersT = TrustedSigners>
90 void SetTrustedSigners(TrustedSignersT&& value) {
91 m_trustedSignersHasBeenSet = true;
92 m_trustedSigners = std::forward<TrustedSignersT>(value);
93 }
94 template <typename TrustedSignersT = TrustedSigners>
95 DefaultCacheBehavior& WithTrustedSigners(TrustedSignersT&& value) {
96 SetTrustedSigners(std::forward<TrustedSignersT>(value));
97 return *this;
98 }
100
102
113 inline const TrustedKeyGroups& GetTrustedKeyGroups() const { return m_trustedKeyGroups; }
114 inline bool TrustedKeyGroupsHasBeenSet() const { return m_trustedKeyGroupsHasBeenSet; }
115 template <typename TrustedKeyGroupsT = TrustedKeyGroups>
116 void SetTrustedKeyGroups(TrustedKeyGroupsT&& value) {
117 m_trustedKeyGroupsHasBeenSet = true;
118 m_trustedKeyGroups = std::forward<TrustedKeyGroupsT>(value);
119 }
120 template <typename TrustedKeyGroupsT = TrustedKeyGroups>
121 DefaultCacheBehavior& WithTrustedKeyGroups(TrustedKeyGroupsT&& value) {
122 SetTrustedKeyGroups(std::forward<TrustedKeyGroupsT>(value));
123 return *this;
124 }
126
128
152 inline ViewerProtocolPolicy GetViewerProtocolPolicy() const { return m_viewerProtocolPolicy; }
153 inline bool ViewerProtocolPolicyHasBeenSet() const { return m_viewerProtocolPolicyHasBeenSet; }
155 m_viewerProtocolPolicyHasBeenSet = true;
156 m_viewerProtocolPolicy = value;
157 }
160 return *this;
161 }
163
165
166 inline const AllowedMethods& GetAllowedMethods() const { return m_allowedMethods; }
167 inline bool AllowedMethodsHasBeenSet() const { return m_allowedMethodsHasBeenSet; }
168 template <typename AllowedMethodsT = AllowedMethods>
169 void SetAllowedMethods(AllowedMethodsT&& value) {
170 m_allowedMethodsHasBeenSet = true;
171 m_allowedMethods = std::forward<AllowedMethodsT>(value);
172 }
173 template <typename AllowedMethodsT = AllowedMethods>
174 DefaultCacheBehavior& WithAllowedMethods(AllowedMethodsT&& value) {
175 SetAllowedMethods(std::forward<AllowedMethodsT>(value));
176 return *this;
177 }
179
181
194 inline bool GetSmoothStreaming() const { return m_smoothStreaming; }
195 inline bool SmoothStreamingHasBeenSet() const { return m_smoothStreamingHasBeenSet; }
196 inline void SetSmoothStreaming(bool value) {
197 m_smoothStreamingHasBeenSet = true;
198 m_smoothStreaming = value;
199 }
201 SetSmoothStreaming(value);
202 return *this;
203 }
205
207
214 inline bool GetCompress() const { return m_compress; }
215 inline bool CompressHasBeenSet() const { return m_compressHasBeenSet; }
216 inline void SetCompress(bool value) {
217 m_compressHasBeenSet = true;
218 m_compress = value;
219 }
220 inline DefaultCacheBehavior& WithCompress(bool value) {
221 SetCompress(value);
222 return *this;
223 }
225
227
231 inline const LambdaFunctionAssociations& GetLambdaFunctionAssociations() const { return m_lambdaFunctionAssociations; }
232 inline bool LambdaFunctionAssociationsHasBeenSet() const { return m_lambdaFunctionAssociationsHasBeenSet; }
233 template <typename LambdaFunctionAssociationsT = LambdaFunctionAssociations>
234 void SetLambdaFunctionAssociations(LambdaFunctionAssociationsT&& value) {
235 m_lambdaFunctionAssociationsHasBeenSet = true;
236 m_lambdaFunctionAssociations = std::forward<LambdaFunctionAssociationsT>(value);
237 }
238 template <typename LambdaFunctionAssociationsT = LambdaFunctionAssociations>
239 DefaultCacheBehavior& WithLambdaFunctionAssociations(LambdaFunctionAssociationsT&& value) {
240 SetLambdaFunctionAssociations(std::forward<LambdaFunctionAssociationsT>(value));
241 return *this;
242 }
244
246
251 inline const FunctionAssociations& GetFunctionAssociations() const { return m_functionAssociations; }
252 inline bool FunctionAssociationsHasBeenSet() const { return m_functionAssociationsHasBeenSet; }
253 template <typename FunctionAssociationsT = FunctionAssociations>
254 void SetFunctionAssociations(FunctionAssociationsT&& value) {
255 m_functionAssociationsHasBeenSet = true;
256 m_functionAssociations = std::forward<FunctionAssociationsT>(value);
257 }
258 template <typename FunctionAssociationsT = FunctionAssociations>
259 DefaultCacheBehavior& WithFunctionAssociations(FunctionAssociationsT&& value) {
260 SetFunctionAssociations(std::forward<FunctionAssociationsT>(value));
261 return *this;
262 }
264
266
271 inline const Aws::String& GetFieldLevelEncryptionId() const { return m_fieldLevelEncryptionId; }
272 inline bool FieldLevelEncryptionIdHasBeenSet() const { return m_fieldLevelEncryptionIdHasBeenSet; }
273 template <typename FieldLevelEncryptionIdT = Aws::String>
274 void SetFieldLevelEncryptionId(FieldLevelEncryptionIdT&& value) {
275 m_fieldLevelEncryptionIdHasBeenSet = true;
276 m_fieldLevelEncryptionId = std::forward<FieldLevelEncryptionIdT>(value);
277 }
278 template <typename FieldLevelEncryptionIdT = Aws::String>
279 DefaultCacheBehavior& WithFieldLevelEncryptionId(FieldLevelEncryptionIdT&& value) {
280 SetFieldLevelEncryptionId(std::forward<FieldLevelEncryptionIdT>(value));
281 return *this;
282 }
284
286
292 inline const Aws::String& GetRealtimeLogConfigArn() const { return m_realtimeLogConfigArn; }
293 inline bool RealtimeLogConfigArnHasBeenSet() const { return m_realtimeLogConfigArnHasBeenSet; }
294 template <typename RealtimeLogConfigArnT = Aws::String>
295 void SetRealtimeLogConfigArn(RealtimeLogConfigArnT&& value) {
296 m_realtimeLogConfigArnHasBeenSet = true;
297 m_realtimeLogConfigArn = std::forward<RealtimeLogConfigArnT>(value);
298 }
299 template <typename RealtimeLogConfigArnT = Aws::String>
300 DefaultCacheBehavior& WithRealtimeLogConfigArn(RealtimeLogConfigArnT&& value) {
301 SetRealtimeLogConfigArn(std::forward<RealtimeLogConfigArnT>(value));
302 return *this;
303 }
305
307
318 inline const Aws::String& GetCachePolicyId() const { return m_cachePolicyId; }
319 inline bool CachePolicyIdHasBeenSet() const { return m_cachePolicyIdHasBeenSet; }
320 template <typename CachePolicyIdT = Aws::String>
321 void SetCachePolicyId(CachePolicyIdT&& value) {
322 m_cachePolicyIdHasBeenSet = true;
323 m_cachePolicyId = std::forward<CachePolicyIdT>(value);
324 }
325 template <typename CachePolicyIdT = Aws::String>
326 DefaultCacheBehavior& WithCachePolicyId(CachePolicyIdT&& value) {
327 SetCachePolicyId(std::forward<CachePolicyIdT>(value));
328 return *this;
329 }
331
333
342 inline const Aws::String& GetOriginRequestPolicyId() const { return m_originRequestPolicyId; }
343 inline bool OriginRequestPolicyIdHasBeenSet() const { return m_originRequestPolicyIdHasBeenSet; }
344 template <typename OriginRequestPolicyIdT = Aws::String>
345 void SetOriginRequestPolicyId(OriginRequestPolicyIdT&& value) {
346 m_originRequestPolicyIdHasBeenSet = true;
347 m_originRequestPolicyId = std::forward<OriginRequestPolicyIdT>(value);
348 }
349 template <typename OriginRequestPolicyIdT = Aws::String>
350 DefaultCacheBehavior& WithOriginRequestPolicyId(OriginRequestPolicyIdT&& value) {
351 SetOriginRequestPolicyId(std::forward<OriginRequestPolicyIdT>(value));
352 return *this;
353 }
355
357
360 inline const Aws::String& GetResponseHeadersPolicyId() const { return m_responseHeadersPolicyId; }
361 inline bool ResponseHeadersPolicyIdHasBeenSet() const { return m_responseHeadersPolicyIdHasBeenSet; }
362 template <typename ResponseHeadersPolicyIdT = Aws::String>
363 void SetResponseHeadersPolicyId(ResponseHeadersPolicyIdT&& value) {
364 m_responseHeadersPolicyIdHasBeenSet = true;
365 m_responseHeadersPolicyId = std::forward<ResponseHeadersPolicyIdT>(value);
366 }
367 template <typename ResponseHeadersPolicyIdT = Aws::String>
368 DefaultCacheBehavior& WithResponseHeadersPolicyId(ResponseHeadersPolicyIdT&& value) {
369 SetResponseHeadersPolicyId(std::forward<ResponseHeadersPolicyIdT>(value));
370 return *this;
371 }
373
375
378 inline const GrpcConfig& GetGrpcConfig() const { return m_grpcConfig; }
379 inline bool GrpcConfigHasBeenSet() const { return m_grpcConfigHasBeenSet; }
380 template <typename GrpcConfigT = GrpcConfig>
381 void SetGrpcConfig(GrpcConfigT&& value) {
382 m_grpcConfigHasBeenSet = true;
383 m_grpcConfig = std::forward<GrpcConfigT>(value);
384 }
385 template <typename GrpcConfigT = GrpcConfig>
386 DefaultCacheBehavior& WithGrpcConfig(GrpcConfigT&& value) {
387 SetGrpcConfig(std::forward<GrpcConfigT>(value));
388 return *this;
389 }
391 private:
392 Aws::String m_targetOriginId;
393
394 TrustedSigners m_trustedSigners;
395
396 TrustedKeyGroups m_trustedKeyGroups;
397
399
400 AllowedMethods m_allowedMethods;
401
402 bool m_smoothStreaming{false};
403
404 bool m_compress{false};
405
406 LambdaFunctionAssociations m_lambdaFunctionAssociations;
407
408 FunctionAssociations m_functionAssociations;
409
410 Aws::String m_fieldLevelEncryptionId;
411
412 Aws::String m_realtimeLogConfigArn;
413
414 Aws::String m_cachePolicyId;
415
416 Aws::String m_originRequestPolicyId;
417
418 Aws::String m_responseHeadersPolicyId;
419
420 GrpcConfig m_grpcConfig;
421 bool m_targetOriginIdHasBeenSet = false;
422 bool m_trustedSignersHasBeenSet = false;
423 bool m_trustedKeyGroupsHasBeenSet = false;
424 bool m_viewerProtocolPolicyHasBeenSet = false;
425 bool m_allowedMethodsHasBeenSet = false;
426 bool m_smoothStreamingHasBeenSet = false;
427 bool m_compressHasBeenSet = false;
428 bool m_lambdaFunctionAssociationsHasBeenSet = false;
429 bool m_functionAssociationsHasBeenSet = false;
430 bool m_fieldLevelEncryptionIdHasBeenSet = false;
431 bool m_realtimeLogConfigArnHasBeenSet = false;
432 bool m_cachePolicyIdHasBeenSet = false;
433 bool m_originRequestPolicyIdHasBeenSet = false;
434 bool m_responseHeadersPolicyIdHasBeenSet = false;
435 bool m_grpcConfigHasBeenSet = false;
436};
437
438} // namespace Model
439} // namespace CloudFront
440} // namespace Aws
void SetRealtimeLogConfigArn(RealtimeLogConfigArnT &&value)
DefaultCacheBehavior & WithCachePolicyId(CachePolicyIdT &&value)
void SetResponseHeadersPolicyId(ResponseHeadersPolicyIdT &&value)
DefaultCacheBehavior & WithLambdaFunctionAssociations(LambdaFunctionAssociationsT &&value)
const FunctionAssociations & GetFunctionAssociations() const
DefaultCacheBehavior & WithRealtimeLogConfigArn(RealtimeLogConfigArnT &&value)
DefaultCacheBehavior & WithTrustedKeyGroups(TrustedKeyGroupsT &&value)
DefaultCacheBehavior & WithAllowedMethods(AllowedMethodsT &&value)
DefaultCacheBehavior & WithViewerProtocolPolicy(ViewerProtocolPolicy value)
AWS_CLOUDFRONT_API void AddToNode(Aws::Utils::Xml::XmlNode &parentNode) const
AWS_CLOUDFRONT_API DefaultCacheBehavior()=default
void SetTrustedKeyGroups(TrustedKeyGroupsT &&value)
DefaultCacheBehavior & WithSmoothStreaming(bool value)
void SetOriginRequestPolicyId(OriginRequestPolicyIdT &&value)
DefaultCacheBehavior & WithGrpcConfig(GrpcConfigT &&value)
const TrustedKeyGroups & GetTrustedKeyGroups() const
DefaultCacheBehavior & WithResponseHeadersPolicyId(ResponseHeadersPolicyIdT &&value)
void SetLambdaFunctionAssociations(LambdaFunctionAssociationsT &&value)
AWS_CLOUDFRONT_API DefaultCacheBehavior & operator=(const Aws::Utils::Xml::XmlNode &xmlNode)
const TrustedSigners & GetTrustedSigners() const
DefaultCacheBehavior & WithTrustedSigners(TrustedSignersT &&value)
DefaultCacheBehavior & WithFieldLevelEncryptionId(FieldLevelEncryptionIdT &&value)
DefaultCacheBehavior & WithFunctionAssociations(FunctionAssociationsT &&value)
AWS_CLOUDFRONT_API DefaultCacheBehavior(const Aws::Utils::Xml::XmlNode &xmlNode)
DefaultCacheBehavior & WithOriginRequestPolicyId(OriginRequestPolicyIdT &&value)
void SetFunctionAssociations(FunctionAssociationsT &&value)
const LambdaFunctionAssociations & GetLambdaFunctionAssociations() const
DefaultCacheBehavior & WithCompress(bool value)
void SetViewerProtocolPolicy(ViewerProtocolPolicy value)
DefaultCacheBehavior & WithTargetOriginId(TargetOriginIdT &&value)
void SetFieldLevelEncryptionId(FieldLevelEncryptionIdT &&value)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String