AWS SDK for C++

AWS SDK for C++ Version 1.11.744

Loading...
Searching...
No Matches
CacheBehaviors.h
1
6#pragma once
7#include <aws/cloudfront/CloudFront_EXPORTS.h>
8#include <aws/cloudfront/model/CacheBehavior.h>
9#include <aws/core/utils/memory/stl/AWSVector.h>
10
11#include <utility>
12
13namespace Aws {
14namespace Utils {
15namespace Xml {
16class XmlNode;
17} // namespace Xml
18} // namespace Utils
19namespace CloudFront {
20namespace Model {
21
29 public:
30 AWS_CLOUDFRONT_API CacheBehaviors() = default;
31 AWS_CLOUDFRONT_API CacheBehaviors(const Aws::Utils::Xml::XmlNode& xmlNode);
32 AWS_CLOUDFRONT_API CacheBehaviors& operator=(const Aws::Utils::Xml::XmlNode& xmlNode);
33
34 AWS_CLOUDFRONT_API void AddToNode(Aws::Utils::Xml::XmlNode& parentNode) const;
35
37
40 inline int GetQuantity() const { return m_quantity; }
41 inline bool QuantityHasBeenSet() const { return m_quantityHasBeenSet; }
42 inline void SetQuantity(int value) {
43 m_quantityHasBeenSet = true;
44 m_quantity = value;
45 }
46 inline CacheBehaviors& WithQuantity(int value) {
47 SetQuantity(value);
48 return *this;
49 }
51
53
57 inline const Aws::Vector<CacheBehavior>& GetItems() const { return m_items; }
58 inline bool ItemsHasBeenSet() const { return m_itemsHasBeenSet; }
59 template <typename ItemsT = Aws::Vector<CacheBehavior>>
60 void SetItems(ItemsT&& value) {
61 m_itemsHasBeenSet = true;
62 m_items = std::forward<ItemsT>(value);
63 }
64 template <typename ItemsT = Aws::Vector<CacheBehavior>>
65 CacheBehaviors& WithItems(ItemsT&& value) {
66 SetItems(std::forward<ItemsT>(value));
67 return *this;
68 }
69 template <typename ItemsT = CacheBehavior>
70 CacheBehaviors& AddItems(ItemsT&& value) {
71 m_itemsHasBeenSet = true;
72 m_items.emplace_back(std::forward<ItemsT>(value));
73 return *this;
74 }
76 private:
77 int m_quantity{0};
78
80 bool m_quantityHasBeenSet = false;
81 bool m_itemsHasBeenSet = false;
82};
83
84} // namespace Model
85} // namespace CloudFront
86} // namespace Aws
AWS_CLOUDFRONT_API CacheBehaviors & operator=(const Aws::Utils::Xml::XmlNode &xmlNode)
CacheBehaviors & WithQuantity(int value)
AWS_CLOUDFRONT_API void AddToNode(Aws::Utils::Xml::XmlNode &parentNode) const
AWS_CLOUDFRONT_API CacheBehaviors()=default
CacheBehaviors & AddItems(ItemsT &&value)
const Aws::Vector< CacheBehavior > & GetItems() const
AWS_CLOUDFRONT_API CacheBehaviors(const Aws::Utils::Xml::XmlNode &xmlNode)
CacheBehaviors & WithItems(ItemsT &&value)
std::vector< T, Aws::Allocator< T > > Vector