AWS SDK for C++  0.12.9
AWS SDK for C++
InternetGateway.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
16 #include <aws/ec2/EC2_EXPORTS.h>
21 #include <aws/ec2/model/Tag.h>
22 
23 namespace Aws
24 {
25 namespace Utils
26 {
27 namespace Xml
28 {
29  class XmlNode;
30 } // namespace Xml
31 } // namespace Utils
32 namespace EC2
33 {
34 namespace Model
35 {
36 
41  {
42  public:
45  InternetGateway& operator=(const Aws::Utils::Xml::XmlNode& xmlNode);
46 
47  void OutputToStream(Aws::OStream& ostream, const char* location, unsigned index, const char* locationValue) const;
48  void OutputToStream(Aws::OStream& oStream, const char* location) const;
49 
53  inline const Aws::String& GetInternetGatewayId() const{ return m_internetGatewayId; }
54 
58  inline void SetInternetGatewayId(const Aws::String& value) { m_internetGatewayIdHasBeenSet = true; m_internetGatewayId = value; }
59 
63  inline void SetInternetGatewayId(Aws::String&& value) { m_internetGatewayIdHasBeenSet = true; m_internetGatewayId = value; }
64 
68  inline void SetInternetGatewayId(const char* value) { m_internetGatewayIdHasBeenSet = true; m_internetGatewayId.assign(value); }
69 
73  inline InternetGateway& WithInternetGatewayId(const Aws::String& value) { SetInternetGatewayId(value); return *this;}
74 
78  inline InternetGateway& WithInternetGatewayId(Aws::String&& value) { SetInternetGatewayId(value); return *this;}
79 
83  inline InternetGateway& WithInternetGatewayId(const char* value) { SetInternetGatewayId(value); return *this;}
84 
88  inline const Aws::Vector<InternetGatewayAttachment>& GetAttachments() const{ return m_attachments; }
89 
93  inline void SetAttachments(const Aws::Vector<InternetGatewayAttachment>& value) { m_attachmentsHasBeenSet = true; m_attachments = value; }
94 
98  inline void SetAttachments(Aws::Vector<InternetGatewayAttachment>&& value) { m_attachmentsHasBeenSet = true; m_attachments = value; }
99 
103  inline InternetGateway& WithAttachments(const Aws::Vector<InternetGatewayAttachment>& value) { SetAttachments(value); return *this;}
104 
108  inline InternetGateway& WithAttachments(Aws::Vector<InternetGatewayAttachment>&& value) { SetAttachments(value); return *this;}
109 
113  inline InternetGateway& AddAttachments(const InternetGatewayAttachment& value) { m_attachmentsHasBeenSet = true; m_attachments.push_back(value); return *this; }
114 
118  inline InternetGateway& AddAttachments(InternetGatewayAttachment&& value) { m_attachmentsHasBeenSet = true; m_attachments.push_back(value); return *this; }
119 
123  inline const Aws::Vector<Tag>& GetTags() const{ return m_tags; }
124 
128  inline void SetTags(const Aws::Vector<Tag>& value) { m_tagsHasBeenSet = true; m_tags = value; }
129 
133  inline void SetTags(Aws::Vector<Tag>&& value) { m_tagsHasBeenSet = true; m_tags = value; }
134 
138  inline InternetGateway& WithTags(const Aws::Vector<Tag>& value) { SetTags(value); return *this;}
139 
143  inline InternetGateway& WithTags(Aws::Vector<Tag>&& value) { SetTags(value); return *this;}
144 
148  inline InternetGateway& AddTags(const Tag& value) { m_tagsHasBeenSet = true; m_tags.push_back(value); return *this; }
149 
153  inline InternetGateway& AddTags(Tag&& value) { m_tagsHasBeenSet = true; m_tags.push_back(value); return *this; }
154 
155  private:
156  Aws::String m_internetGatewayId;
157  bool m_internetGatewayIdHasBeenSet;
159  bool m_attachmentsHasBeenSet;
160  Aws::Vector<Tag> m_tags;
161  bool m_tagsHasBeenSet;
162  };
163 
164 } // namespace Model
165 } // namespace EC2
166 } // namespace Aws
InternetGateway & AddAttachments(InternetGatewayAttachment &&value)
InternetGateway & WithTags(const Aws::Vector< Tag > &value)
InternetGateway & WithAttachments(const Aws::Vector< InternetGatewayAttachment > &value)
std::vector< T, Aws::Allocator< T > > Vector
Definition: AWSVector.h:27
void SetTags(const Aws::Vector< Tag > &value)
InternetGateway & WithInternetGatewayId(const Aws::String &value)
void SetInternetGatewayId(const Aws::String &value)
InternetGateway & AddAttachments(const InternetGatewayAttachment &value)
const Aws::Vector< Tag > & GetTags() const
InternetGateway & AddTags(Tag &&value)
std::basic_ostream< char, std::char_traits< char > > OStream
Definition: AWSStreamFwd.h:31
InternetGateway & WithInternetGatewayId(const char *value)
void SetTags(Aws::Vector< Tag > &&value)
InternetGateway & WithInternetGatewayId(Aws::String &&value)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Definition: AWSString.h:97
const Aws::Vector< InternetGatewayAttachment > & GetAttachments() const
InternetGateway & WithTags(Aws::Vector< Tag > &&value)
const Aws::String & GetInternetGatewayId() const
void SetAttachments(Aws::Vector< InternetGatewayAttachment > &&value)
InternetGateway & AddTags(const Tag &value)
void SetInternetGatewayId(Aws::String &&value)
void SetInternetGatewayId(const char *value)
InternetGateway & WithAttachments(Aws::Vector< InternetGatewayAttachment > &&value)
#define AWS_EC2_API
Definition: EC2_EXPORTS.h:34
void SetAttachments(const Aws::Vector< InternetGatewayAttachment > &value)
JSON (JavaScript Object Notation).