AWS SDK for C++  1.9.160
AWS SDK for C++
GeoRestriction.h
Go to the documentation of this file.
1 
6 #pragma once
11 #include <utility>
12 
13 namespace Aws
14 {
15 namespace Utils
16 {
17 namespace Xml
18 {
19  class XmlNode;
20 } // namespace Xml
21 } // namespace Utils
22 namespace CloudFront
23 {
24 namespace Model
25 {
26 
35  {
36  public:
40 
41  void AddToNode(Aws::Utils::Xml::XmlNode& parentNode) const;
42 
43 
54  inline const GeoRestrictionType& GetRestrictionType() const{ return m_restrictionType; }
55 
66  inline bool RestrictionTypeHasBeenSet() const { return m_restrictionTypeHasBeenSet; }
67 
78  inline void SetRestrictionType(const GeoRestrictionType& value) { m_restrictionTypeHasBeenSet = true; m_restrictionType = value; }
79 
90  inline void SetRestrictionType(GeoRestrictionType&& value) { m_restrictionTypeHasBeenSet = true; m_restrictionType = std::move(value); }
91 
102  inline GeoRestriction& WithRestrictionType(const GeoRestrictionType& value) { SetRestrictionType(value); return *this;}
103 
114  inline GeoRestriction& WithRestrictionType(GeoRestrictionType&& value) { SetRestrictionType(std::move(value)); return *this;}
115 
116 
123  inline int GetQuantity() const{ return m_quantity; }
124 
131  inline bool QuantityHasBeenSet() const { return m_quantityHasBeenSet; }
132 
139  inline void SetQuantity(int value) { m_quantityHasBeenSet = true; m_quantity = value; }
140 
147  inline GeoRestriction& WithQuantity(int value) { SetQuantity(value); return *this;}
148 
149 
164  inline const Aws::Vector<Aws::String>& GetItems() const{ return m_items; }
165 
180  inline bool ItemsHasBeenSet() const { return m_itemsHasBeenSet; }
181 
196  inline void SetItems(const Aws::Vector<Aws::String>& value) { m_itemsHasBeenSet = true; m_items = value; }
197 
212  inline void SetItems(Aws::Vector<Aws::String>&& value) { m_itemsHasBeenSet = true; m_items = std::move(value); }
213 
228  inline GeoRestriction& WithItems(const Aws::Vector<Aws::String>& value) { SetItems(value); return *this;}
229 
244  inline GeoRestriction& WithItems(Aws::Vector<Aws::String>&& value) { SetItems(std::move(value)); return *this;}
245 
260  inline GeoRestriction& AddItems(const Aws::String& value) { m_itemsHasBeenSet = true; m_items.push_back(value); return *this; }
261 
276  inline GeoRestriction& AddItems(Aws::String&& value) { m_itemsHasBeenSet = true; m_items.push_back(std::move(value)); return *this; }
277 
292  inline GeoRestriction& AddItems(const char* value) { m_itemsHasBeenSet = true; m_items.push_back(value); return *this; }
293 
294  private:
295 
296  GeoRestrictionType m_restrictionType;
297  bool m_restrictionTypeHasBeenSet;
298 
299  int m_quantity;
300  bool m_quantityHasBeenSet;
301 
302  Aws::Vector<Aws::String> m_items;
303  bool m_itemsHasBeenSet;
304  };
305 
306 } // namespace Model
307 } // namespace CloudFront
308 } // namespace Aws
Aws::CloudFront::Model::GeoRestriction::SetRestrictionType
void SetRestrictionType(GeoRestrictionType &&value)
Definition: GeoRestriction.h:90
Aws::CloudFront::Model::GeoRestrictionType
GeoRestrictionType
Definition: GeoRestrictionType.h:17
Aws::Vector
std::vector< T, Aws::Allocator< T > > Vector
Definition: AWSVector.h:17
Aws::CloudFront::Model::GeoRestriction::SetQuantity
void SetQuantity(int value)
Definition: GeoRestriction.h:139
Aws::CloudFront::Model::GeoRestriction::GeoRestriction
GeoRestriction(const Aws::Utils::Xml::XmlNode &xmlNode)
AWSVector.h
Aws::CloudFront::Model::GeoRestriction::GeoRestriction
GeoRestriction()
Aws::CloudFront::Model::GeoRestriction::QuantityHasBeenSet
bool QuantityHasBeenSet() const
Definition: GeoRestriction.h:131
Aws::CloudFront::Model::GeoRestriction::SetItems
void SetItems(const Aws::Vector< Aws::String > &value)
Definition: GeoRestriction.h:196
Aws::Utils::Xml::XmlNode
Definition: XmlSerializer.h:53
Aws::CloudFront::Model::GeoRestriction::SetRestrictionType
void SetRestrictionType(const GeoRestrictionType &value)
Definition: GeoRestriction.h:78
Aws::CloudFront::Model::GeoRestriction::WithQuantity
GeoRestriction & WithQuantity(int value)
Definition: GeoRestriction.h:147
Aws::CloudFront::Model::GeoRestriction::AddItems
GeoRestriction & AddItems(Aws::String &&value)
Definition: GeoRestriction.h:276
GeoRestrictionType.h
AWSString.h
Aws::CloudFront::Model::GeoRestriction::RestrictionTypeHasBeenSet
bool RestrictionTypeHasBeenSet() const
Definition: GeoRestriction.h:66
Aws::CloudFront::Model::GeoRestriction::AddItems
GeoRestriction & AddItems(const char *value)
Definition: GeoRestriction.h:292
Aws::CloudFront::Model::GeoRestriction::WithRestrictionType
GeoRestriction & WithRestrictionType(GeoRestrictionType &&value)
Definition: GeoRestriction.h:114
AWS_CLOUDFRONT_API
#define AWS_CLOUDFRONT_API
Definition: CloudFront_EXPORTS.h:28
Aws::CloudFront::Model::GeoRestriction::GetRestrictionType
const GeoRestrictionType & GetRestrictionType() const
Definition: GeoRestriction.h:54
CloudFront_EXPORTS.h
Aws::CloudFront::Model::GeoRestriction::ItemsHasBeenSet
bool ItemsHasBeenSet() const
Definition: GeoRestriction.h:180
Aws::CloudFront::Model::GeoRestriction::AddItems
GeoRestriction & AddItems(const Aws::String &value)
Definition: GeoRestriction.h:260
Aws
Definition: AccessManagementClient.h:15
Aws::CloudFront::Model::GeoRestriction::GetItems
const Aws::Vector< Aws::String > & GetItems() const
Definition: GeoRestriction.h:164
Aws::CloudFront::Model::GeoRestriction::operator=
GeoRestriction & operator=(const Aws::Utils::Xml::XmlNode &xmlNode)
Aws::CloudFront::Model::GeoRestriction::WithRestrictionType
GeoRestriction & WithRestrictionType(const GeoRestrictionType &value)
Definition: GeoRestriction.h:102
Aws::CloudFront::Model::GeoRestriction::AddToNode
void AddToNode(Aws::Utils::Xml::XmlNode &parentNode) const
Aws::String
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Definition: AWSString.h:97
Aws::CloudFront::Model::GeoRestriction::WithItems
GeoRestriction & WithItems(Aws::Vector< Aws::String > &&value)
Definition: GeoRestriction.h:244
Aws::CloudFront::Model::GeoRestriction::WithItems
GeoRestriction & WithItems(const Aws::Vector< Aws::String > &value)
Definition: GeoRestriction.h:228
Aws::CloudFront::Model::GeoRestriction::GetQuantity
int GetQuantity() const
Definition: GeoRestriction.h:123
Aws::CloudFront::Model::GeoRestriction::SetItems
void SetItems(Aws::Vector< Aws::String > &&value)
Definition: GeoRestriction.h:212
Aws::CloudFront::Model::GeoRestriction
Definition: GeoRestriction.h:35