AWS SDK for C++  0.12.9
AWS SDK for C++
DefaultCacheBehavior.h
Go to the documentation of this file.
1 /*
2 * Copyright 2010-2016 Amazon.com, Inc. or its affiliates. All Rights Reserved.
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License").
5 * You may not use this file except in compliance with the License.
6 * A copy of the License is located at
7 *
8 * http://aws.amazon.com/apache2.0
9 *
10 * or in the "license" file accompanying this file. This file is distributed
11 * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
12 * express or implied. See the License for the specific language governing
13 * permissions and limitations under the License.
14 */
15 #pragma once
22 
23 namespace Aws
24 {
25 namespace Utils
26 {
27 namespace Xml
28 {
29  class XmlNode;
30 } // namespace Xml
31 } // namespace Utils
32 namespace CloudFront
33 {
34 namespace Model
35 {
36 
43  {
44  public:
47  DefaultCacheBehavior& operator=(const Aws::Utils::Xml::XmlNode& xmlNode);
48 
49  void AddToNode(Aws::Utils::Xml::XmlNode& parentNode) const;
50 
56  inline const Aws::String& GetTargetOriginId() const{ return m_targetOriginId; }
57 
63  inline void SetTargetOriginId(const Aws::String& value) { m_targetOriginIdHasBeenSet = true; m_targetOriginId = value; }
64 
70  inline void SetTargetOriginId(Aws::String&& value) { m_targetOriginIdHasBeenSet = true; m_targetOriginId = value; }
71 
77  inline void SetTargetOriginId(const char* value) { m_targetOriginIdHasBeenSet = true; m_targetOriginId.assign(value); }
78 
84  inline DefaultCacheBehavior& WithTargetOriginId(const Aws::String& value) { SetTargetOriginId(value); return *this;}
85 
91  inline DefaultCacheBehavior& WithTargetOriginId(Aws::String&& value) { SetTargetOriginId(value); return *this;}
92 
98  inline DefaultCacheBehavior& WithTargetOriginId(const char* value) { SetTargetOriginId(value); return *this;}
99 
104  inline const ForwardedValues& GetForwardedValues() const{ return m_forwardedValues; }
105 
110  inline void SetForwardedValues(const ForwardedValues& value) { m_forwardedValuesHasBeenSet = true; m_forwardedValues = value; }
111 
116  inline void SetForwardedValues(ForwardedValues&& value) { m_forwardedValuesHasBeenSet = true; m_forwardedValues = value; }
117 
122  inline DefaultCacheBehavior& WithForwardedValues(const ForwardedValues& value) { SetForwardedValues(value); return *this;}
123 
128  inline DefaultCacheBehavior& WithForwardedValues(ForwardedValues&& value) { SetForwardedValues(value); return *this;}
129 
143  inline const TrustedSigners& GetTrustedSigners() const{ return m_trustedSigners; }
144 
158  inline void SetTrustedSigners(const TrustedSigners& value) { m_trustedSignersHasBeenSet = true; m_trustedSigners = value; }
159 
173  inline void SetTrustedSigners(TrustedSigners&& value) { m_trustedSignersHasBeenSet = true; m_trustedSigners = value; }
174 
188  inline DefaultCacheBehavior& WithTrustedSigners(const TrustedSigners& value) { SetTrustedSigners(value); return *this;}
189 
203  inline DefaultCacheBehavior& WithTrustedSigners(TrustedSigners&& value) { SetTrustedSigners(value); return *this;}
204 
214  inline const ViewerProtocolPolicy& GetViewerProtocolPolicy() const{ return m_viewerProtocolPolicy; }
215 
225  inline void SetViewerProtocolPolicy(const ViewerProtocolPolicy& value) { m_viewerProtocolPolicyHasBeenSet = true; m_viewerProtocolPolicy = value; }
226 
236  inline void SetViewerProtocolPolicy(ViewerProtocolPolicy&& value) { m_viewerProtocolPolicyHasBeenSet = true; m_viewerProtocolPolicy = value; }
237 
247  inline DefaultCacheBehavior& WithViewerProtocolPolicy(const ViewerProtocolPolicy& value) { SetViewerProtocolPolicy(value); return *this;}
248 
258  inline DefaultCacheBehavior& WithViewerProtocolPolicy(ViewerProtocolPolicy&& value) { SetViewerProtocolPolicy(value); return *this;}
259 
265  inline long long GetMinTTL() const{ return m_minTTL; }
266 
272  inline void SetMinTTL(long long value) { m_minTTLHasBeenSet = true; m_minTTL = value; }
273 
279  inline DefaultCacheBehavior& WithMinTTL(long long value) { SetMinTTL(value); return *this;}
280 
281 
282  inline const AllowedMethods& GetAllowedMethods() const{ return m_allowedMethods; }
283 
284 
285  inline void SetAllowedMethods(const AllowedMethods& value) { m_allowedMethodsHasBeenSet = true; m_allowedMethods = value; }
286 
287 
288  inline void SetAllowedMethods(AllowedMethods&& value) { m_allowedMethodsHasBeenSet = true; m_allowedMethods = value; }
289 
290 
291  inline DefaultCacheBehavior& WithAllowedMethods(const AllowedMethods& value) { SetAllowedMethods(value); return *this;}
292 
293 
294  inline DefaultCacheBehavior& WithAllowedMethods(AllowedMethods&& value) { SetAllowedMethods(value); return *this;}
295 
301  inline bool GetSmoothStreaming() const{ return m_smoothStreaming; }
302 
308  inline void SetSmoothStreaming(bool value) { m_smoothStreamingHasBeenSet = true; m_smoothStreaming = value; }
309 
315  inline DefaultCacheBehavior& WithSmoothStreaming(bool value) { SetSmoothStreaming(value); return *this;}
316 
326  inline long long GetDefaultTTL() const{ return m_defaultTTL; }
327 
337  inline void SetDefaultTTL(long long value) { m_defaultTTLHasBeenSet = true; m_defaultTTL = value; }
338 
348  inline DefaultCacheBehavior& WithDefaultTTL(long long value) { SetDefaultTTL(value); return *this;}
349 
358  inline long long GetMaxTTL() const{ return m_maxTTL; }
359 
368  inline void SetMaxTTL(long long value) { m_maxTTLHasBeenSet = true; m_maxTTL = value; }
369 
378  inline DefaultCacheBehavior& WithMaxTTL(long long value) { SetMaxTTL(value); return *this;}
379 
398  inline bool GetCompress() const{ return m_compress; }
399 
418  inline void SetCompress(bool value) { m_compressHasBeenSet = true; m_compress = value; }
419 
438  inline DefaultCacheBehavior& WithCompress(bool value) { SetCompress(value); return *this;}
439 
440  private:
441  Aws::String m_targetOriginId;
442  bool m_targetOriginIdHasBeenSet;
443  ForwardedValues m_forwardedValues;
444  bool m_forwardedValuesHasBeenSet;
445  TrustedSigners m_trustedSigners;
446  bool m_trustedSignersHasBeenSet;
447  ViewerProtocolPolicy m_viewerProtocolPolicy;
448  bool m_viewerProtocolPolicyHasBeenSet;
449  long long m_minTTL;
450  bool m_minTTLHasBeenSet;
451  AllowedMethods m_allowedMethods;
452  bool m_allowedMethodsHasBeenSet;
453  bool m_smoothStreaming;
454  bool m_smoothStreamingHasBeenSet;
455  long long m_defaultTTL;
456  bool m_defaultTTLHasBeenSet;
457  long long m_maxTTL;
458  bool m_maxTTLHasBeenSet;
459  bool m_compress;
460  bool m_compressHasBeenSet;
461  };
462 
463 } // namespace Model
464 } // namespace CloudFront
465 } // namespace Aws
DefaultCacheBehavior & WithTargetOriginId(const char *value)
DefaultCacheBehavior & WithTrustedSigners(TrustedSigners &&value)
void SetTargetOriginId(const Aws::String &value)
void SetForwardedValues(const ForwardedValues &value)
DefaultCacheBehavior & WithMinTTL(long long value)
DefaultCacheBehavior & WithSmoothStreaming(bool value)
void SetViewerProtocolPolicy(const ViewerProtocolPolicy &value)
DefaultCacheBehavior & WithTargetOriginId(Aws::String &&value)
const ViewerProtocolPolicy & GetViewerProtocolPolicy() const
DefaultCacheBehavior & WithViewerProtocolPolicy(ViewerProtocolPolicy &&value)
DefaultCacheBehavior & WithForwardedValues(ForwardedValues &&value)
DefaultCacheBehavior & WithDefaultTTL(long long value)
DefaultCacheBehavior & WithMaxTTL(long long value)
DefaultCacheBehavior & WithForwardedValues(const ForwardedValues &value)
const ForwardedValues & GetForwardedValues() const
#define AWS_CLOUDFRONT_API
DefaultCacheBehavior & WithTrustedSigners(const TrustedSigners &value)
DefaultCacheBehavior & WithAllowedMethods(AllowedMethods &&value)
void SetViewerProtocolPolicy(ViewerProtocolPolicy &&value)
const TrustedSigners & GetTrustedSigners() const
DefaultCacheBehavior & WithTargetOriginId(const Aws::String &value)
void SetTrustedSigners(const TrustedSigners &value)
void SetAllowedMethods(const AllowedMethods &value)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Definition: AWSString.h:97
DefaultCacheBehavior & WithViewerProtocolPolicy(const ViewerProtocolPolicy &value)
const AllowedMethods & GetAllowedMethods() const
DefaultCacheBehavior & WithAllowedMethods(const AllowedMethods &value)
JSON (JavaScript Object Notation).
void SetForwardedValues(ForwardedValues &&value)
DefaultCacheBehavior & WithCompress(bool value)