AWS SDK for C++

AWS SDK for C++ Version 1.11.717

Loading...
Searching...
No Matches
Route.h
1
6#pragma once
7#include <aws/core/utils/memory/stl/AWSStreamFwd.h>
8#include <aws/core/utils/memory/stl/AWSString.h>
9#include <aws/ec2/EC2_EXPORTS.h>
10#include <aws/ec2/model/RouteOrigin.h>
11#include <aws/ec2/model/RouteState.h>
12
13#include <utility>
14
15namespace Aws {
16namespace Utils {
17namespace Xml {
18class XmlNode;
19} // namespace Xml
20} // namespace Utils
21namespace EC2 {
22namespace Model {
23
29class Route {
30 public:
31 AWS_EC2_API Route() = default;
32 AWS_EC2_API Route(const Aws::Utils::Xml::XmlNode& xmlNode);
33 AWS_EC2_API Route& operator=(const Aws::Utils::Xml::XmlNode& xmlNode);
34
35 AWS_EC2_API void OutputToStream(Aws::OStream& ostream, const char* location, unsigned index, const char* locationValue) const;
36 AWS_EC2_API void OutputToStream(Aws::OStream& oStream, const char* location) const;
37
39
42 inline const Aws::String& GetDestinationCidrBlock() const { return m_destinationCidrBlock; }
43 inline bool DestinationCidrBlockHasBeenSet() const { return m_destinationCidrBlockHasBeenSet; }
44 template <typename DestinationCidrBlockT = Aws::String>
45 void SetDestinationCidrBlock(DestinationCidrBlockT&& value) {
46 m_destinationCidrBlockHasBeenSet = true;
47 m_destinationCidrBlock = std::forward<DestinationCidrBlockT>(value);
48 }
49 template <typename DestinationCidrBlockT = Aws::String>
50 Route& WithDestinationCidrBlock(DestinationCidrBlockT&& value) {
51 SetDestinationCidrBlock(std::forward<DestinationCidrBlockT>(value));
52 return *this;
53 }
55
57
60 inline const Aws::String& GetDestinationIpv6CidrBlock() const { return m_destinationIpv6CidrBlock; }
61 inline bool DestinationIpv6CidrBlockHasBeenSet() const { return m_destinationIpv6CidrBlockHasBeenSet; }
62 template <typename DestinationIpv6CidrBlockT = Aws::String>
63 void SetDestinationIpv6CidrBlock(DestinationIpv6CidrBlockT&& value) {
64 m_destinationIpv6CidrBlockHasBeenSet = true;
65 m_destinationIpv6CidrBlock = std::forward<DestinationIpv6CidrBlockT>(value);
66 }
67 template <typename DestinationIpv6CidrBlockT = Aws::String>
68 Route& WithDestinationIpv6CidrBlock(DestinationIpv6CidrBlockT&& value) {
69 SetDestinationIpv6CidrBlock(std::forward<DestinationIpv6CidrBlockT>(value));
70 return *this;
71 }
73
75
78 inline const Aws::String& GetDestinationPrefixListId() const { return m_destinationPrefixListId; }
79 inline bool DestinationPrefixListIdHasBeenSet() const { return m_destinationPrefixListIdHasBeenSet; }
80 template <typename DestinationPrefixListIdT = Aws::String>
81 void SetDestinationPrefixListId(DestinationPrefixListIdT&& value) {
82 m_destinationPrefixListIdHasBeenSet = true;
83 m_destinationPrefixListId = std::forward<DestinationPrefixListIdT>(value);
84 }
85 template <typename DestinationPrefixListIdT = Aws::String>
86 Route& WithDestinationPrefixListId(DestinationPrefixListIdT&& value) {
87 SetDestinationPrefixListId(std::forward<DestinationPrefixListIdT>(value));
88 return *this;
89 }
91
93
96 inline const Aws::String& GetEgressOnlyInternetGatewayId() const { return m_egressOnlyInternetGatewayId; }
97 inline bool EgressOnlyInternetGatewayIdHasBeenSet() const { return m_egressOnlyInternetGatewayIdHasBeenSet; }
98 template <typename EgressOnlyInternetGatewayIdT = Aws::String>
99 void SetEgressOnlyInternetGatewayId(EgressOnlyInternetGatewayIdT&& value) {
100 m_egressOnlyInternetGatewayIdHasBeenSet = true;
101 m_egressOnlyInternetGatewayId = std::forward<EgressOnlyInternetGatewayIdT>(value);
102 }
103 template <typename EgressOnlyInternetGatewayIdT = Aws::String>
104 Route& WithEgressOnlyInternetGatewayId(EgressOnlyInternetGatewayIdT&& value) {
105 SetEgressOnlyInternetGatewayId(std::forward<EgressOnlyInternetGatewayIdT>(value));
106 return *this;
107 }
109
111
114 inline const Aws::String& GetGatewayId() const { return m_gatewayId; }
115 inline bool GatewayIdHasBeenSet() const { return m_gatewayIdHasBeenSet; }
116 template <typename GatewayIdT = Aws::String>
117 void SetGatewayId(GatewayIdT&& value) {
118 m_gatewayIdHasBeenSet = true;
119 m_gatewayId = std::forward<GatewayIdT>(value);
120 }
121 template <typename GatewayIdT = Aws::String>
122 Route& WithGatewayId(GatewayIdT&& value) {
123 SetGatewayId(std::forward<GatewayIdT>(value));
124 return *this;
125 }
127
129
132 inline const Aws::String& GetInstanceId() const { return m_instanceId; }
133 inline bool InstanceIdHasBeenSet() const { return m_instanceIdHasBeenSet; }
134 template <typename InstanceIdT = Aws::String>
135 void SetInstanceId(InstanceIdT&& value) {
136 m_instanceIdHasBeenSet = true;
137 m_instanceId = std::forward<InstanceIdT>(value);
138 }
139 template <typename InstanceIdT = Aws::String>
140 Route& WithInstanceId(InstanceIdT&& value) {
141 SetInstanceId(std::forward<InstanceIdT>(value));
142 return *this;
143 }
145
147
150 inline const Aws::String& GetInstanceOwnerId() const { return m_instanceOwnerId; }
151 inline bool InstanceOwnerIdHasBeenSet() const { return m_instanceOwnerIdHasBeenSet; }
152 template <typename InstanceOwnerIdT = Aws::String>
153 void SetInstanceOwnerId(InstanceOwnerIdT&& value) {
154 m_instanceOwnerIdHasBeenSet = true;
155 m_instanceOwnerId = std::forward<InstanceOwnerIdT>(value);
156 }
157 template <typename InstanceOwnerIdT = Aws::String>
158 Route& WithInstanceOwnerId(InstanceOwnerIdT&& value) {
159 SetInstanceOwnerId(std::forward<InstanceOwnerIdT>(value));
160 return *this;
161 }
163
165
168 inline const Aws::String& GetNatGatewayId() const { return m_natGatewayId; }
169 inline bool NatGatewayIdHasBeenSet() const { return m_natGatewayIdHasBeenSet; }
170 template <typename NatGatewayIdT = Aws::String>
171 void SetNatGatewayId(NatGatewayIdT&& value) {
172 m_natGatewayIdHasBeenSet = true;
173 m_natGatewayId = std::forward<NatGatewayIdT>(value);
174 }
175 template <typename NatGatewayIdT = Aws::String>
176 Route& WithNatGatewayId(NatGatewayIdT&& value) {
177 SetNatGatewayId(std::forward<NatGatewayIdT>(value));
178 return *this;
179 }
181
183
186 inline const Aws::String& GetTransitGatewayId() const { return m_transitGatewayId; }
187 inline bool TransitGatewayIdHasBeenSet() const { return m_transitGatewayIdHasBeenSet; }
188 template <typename TransitGatewayIdT = Aws::String>
189 void SetTransitGatewayId(TransitGatewayIdT&& value) {
190 m_transitGatewayIdHasBeenSet = true;
191 m_transitGatewayId = std::forward<TransitGatewayIdT>(value);
192 }
193 template <typename TransitGatewayIdT = Aws::String>
194 Route& WithTransitGatewayId(TransitGatewayIdT&& value) {
195 SetTransitGatewayId(std::forward<TransitGatewayIdT>(value));
196 return *this;
197 }
199
201
204 inline const Aws::String& GetLocalGatewayId() const { return m_localGatewayId; }
205 inline bool LocalGatewayIdHasBeenSet() const { return m_localGatewayIdHasBeenSet; }
206 template <typename LocalGatewayIdT = Aws::String>
207 void SetLocalGatewayId(LocalGatewayIdT&& value) {
208 m_localGatewayIdHasBeenSet = true;
209 m_localGatewayId = std::forward<LocalGatewayIdT>(value);
210 }
211 template <typename LocalGatewayIdT = Aws::String>
212 Route& WithLocalGatewayId(LocalGatewayIdT&& value) {
213 SetLocalGatewayId(std::forward<LocalGatewayIdT>(value));
214 return *this;
215 }
217
219
222 inline const Aws::String& GetCarrierGatewayId() const { return m_carrierGatewayId; }
223 inline bool CarrierGatewayIdHasBeenSet() const { return m_carrierGatewayIdHasBeenSet; }
224 template <typename CarrierGatewayIdT = Aws::String>
225 void SetCarrierGatewayId(CarrierGatewayIdT&& value) {
226 m_carrierGatewayIdHasBeenSet = true;
227 m_carrierGatewayId = std::forward<CarrierGatewayIdT>(value);
228 }
229 template <typename CarrierGatewayIdT = Aws::String>
230 Route& WithCarrierGatewayId(CarrierGatewayIdT&& value) {
231 SetCarrierGatewayId(std::forward<CarrierGatewayIdT>(value));
232 return *this;
233 }
235
237
240 inline const Aws::String& GetNetworkInterfaceId() const { return m_networkInterfaceId; }
241 inline bool NetworkInterfaceIdHasBeenSet() const { return m_networkInterfaceIdHasBeenSet; }
242 template <typename NetworkInterfaceIdT = Aws::String>
243 void SetNetworkInterfaceId(NetworkInterfaceIdT&& value) {
244 m_networkInterfaceIdHasBeenSet = true;
245 m_networkInterfaceId = std::forward<NetworkInterfaceIdT>(value);
246 }
247 template <typename NetworkInterfaceIdT = Aws::String>
248 Route& WithNetworkInterfaceId(NetworkInterfaceIdT&& value) {
249 SetNetworkInterfaceId(std::forward<NetworkInterfaceIdT>(value));
250 return *this;
251 }
253
255
264 inline RouteOrigin GetOrigin() const { return m_origin; }
265 inline bool OriginHasBeenSet() const { return m_originHasBeenSet; }
266 inline void SetOrigin(RouteOrigin value) {
267 m_originHasBeenSet = true;
268 m_origin = value;
269 }
270 inline Route& WithOrigin(RouteOrigin value) {
271 SetOrigin(value);
272 return *this;
273 }
275
277
282 inline RouteState GetState() const { return m_state; }
283 inline bool StateHasBeenSet() const { return m_stateHasBeenSet; }
284 inline void SetState(RouteState value) {
285 m_stateHasBeenSet = true;
286 m_state = value;
287 }
288 inline Route& WithState(RouteState value) {
289 SetState(value);
290 return *this;
291 }
293
295
298 inline const Aws::String& GetVpcPeeringConnectionId() const { return m_vpcPeeringConnectionId; }
299 inline bool VpcPeeringConnectionIdHasBeenSet() const { return m_vpcPeeringConnectionIdHasBeenSet; }
300 template <typename VpcPeeringConnectionIdT = Aws::String>
301 void SetVpcPeeringConnectionId(VpcPeeringConnectionIdT&& value) {
302 m_vpcPeeringConnectionIdHasBeenSet = true;
303 m_vpcPeeringConnectionId = std::forward<VpcPeeringConnectionIdT>(value);
304 }
305 template <typename VpcPeeringConnectionIdT = Aws::String>
306 Route& WithVpcPeeringConnectionId(VpcPeeringConnectionIdT&& value) {
307 SetVpcPeeringConnectionId(std::forward<VpcPeeringConnectionIdT>(value));
308 return *this;
309 }
311
313
316 inline const Aws::String& GetCoreNetworkArn() const { return m_coreNetworkArn; }
317 inline bool CoreNetworkArnHasBeenSet() const { return m_coreNetworkArnHasBeenSet; }
318 template <typename CoreNetworkArnT = Aws::String>
319 void SetCoreNetworkArn(CoreNetworkArnT&& value) {
320 m_coreNetworkArnHasBeenSet = true;
321 m_coreNetworkArn = std::forward<CoreNetworkArnT>(value);
322 }
323 template <typename CoreNetworkArnT = Aws::String>
324 Route& WithCoreNetworkArn(CoreNetworkArnT&& value) {
325 SetCoreNetworkArn(std::forward<CoreNetworkArnT>(value));
326 return *this;
327 }
329
331
334 inline const Aws::String& GetOdbNetworkArn() const { return m_odbNetworkArn; }
335 inline bool OdbNetworkArnHasBeenSet() const { return m_odbNetworkArnHasBeenSet; }
336 template <typename OdbNetworkArnT = Aws::String>
337 void SetOdbNetworkArn(OdbNetworkArnT&& value) {
338 m_odbNetworkArnHasBeenSet = true;
339 m_odbNetworkArn = std::forward<OdbNetworkArnT>(value);
340 }
341 template <typename OdbNetworkArnT = Aws::String>
342 Route& WithOdbNetworkArn(OdbNetworkArnT&& value) {
343 SetOdbNetworkArn(std::forward<OdbNetworkArnT>(value));
344 return *this;
345 }
347
349
353 inline const Aws::String& GetIpAddress() const { return m_ipAddress; }
354 inline bool IpAddressHasBeenSet() const { return m_ipAddressHasBeenSet; }
355 template <typename IpAddressT = Aws::String>
356 void SetIpAddress(IpAddressT&& value) {
357 m_ipAddressHasBeenSet = true;
358 m_ipAddress = std::forward<IpAddressT>(value);
359 }
360 template <typename IpAddressT = Aws::String>
361 Route& WithIpAddress(IpAddressT&& value) {
362 SetIpAddress(std::forward<IpAddressT>(value));
363 return *this;
364 }
366 private:
367 Aws::String m_destinationCidrBlock;
368
369 Aws::String m_destinationIpv6CidrBlock;
370
371 Aws::String m_destinationPrefixListId;
372
373 Aws::String m_egressOnlyInternetGatewayId;
374
375 Aws::String m_gatewayId;
376
377 Aws::String m_instanceId;
378
379 Aws::String m_instanceOwnerId;
380
381 Aws::String m_natGatewayId;
382
383 Aws::String m_transitGatewayId;
384
385 Aws::String m_localGatewayId;
386
387 Aws::String m_carrierGatewayId;
388
389 Aws::String m_networkInterfaceId;
390
392
394
395 Aws::String m_vpcPeeringConnectionId;
396
397 Aws::String m_coreNetworkArn;
398
399 Aws::String m_odbNetworkArn;
400
401 Aws::String m_ipAddress;
402 bool m_destinationCidrBlockHasBeenSet = false;
403 bool m_destinationIpv6CidrBlockHasBeenSet = false;
404 bool m_destinationPrefixListIdHasBeenSet = false;
405 bool m_egressOnlyInternetGatewayIdHasBeenSet = false;
406 bool m_gatewayIdHasBeenSet = false;
407 bool m_instanceIdHasBeenSet = false;
408 bool m_instanceOwnerIdHasBeenSet = false;
409 bool m_natGatewayIdHasBeenSet = false;
410 bool m_transitGatewayIdHasBeenSet = false;
411 bool m_localGatewayIdHasBeenSet = false;
412 bool m_carrierGatewayIdHasBeenSet = false;
413 bool m_networkInterfaceIdHasBeenSet = false;
414 bool m_originHasBeenSet = false;
415 bool m_stateHasBeenSet = false;
416 bool m_vpcPeeringConnectionIdHasBeenSet = false;
417 bool m_coreNetworkArnHasBeenSet = false;
418 bool m_odbNetworkArnHasBeenSet = false;
419 bool m_ipAddressHasBeenSet = false;
420};
421
422} // namespace Model
423} // namespace EC2
424} // namespace Aws
AWS_EC2_API void OutputToStream(Aws::OStream &oStream, const char *location) const
Route & WithInstanceId(InstanceIdT &&value)
Definition Route.h:140
Route & WithTransitGatewayId(TransitGatewayIdT &&value)
Definition Route.h:194
void SetGatewayId(GatewayIdT &&value)
Definition Route.h:117
const Aws::String & GetTransitGatewayId() const
Definition Route.h:186
Route & WithOrigin(RouteOrigin value)
Definition Route.h:270
Route & WithGatewayId(GatewayIdT &&value)
Definition Route.h:122
Route & WithCoreNetworkArn(CoreNetworkArnT &&value)
Definition Route.h:324
bool TransitGatewayIdHasBeenSet() const
Definition Route.h:187
const Aws::String & GetVpcPeeringConnectionId() const
Definition Route.h:298
const Aws::String & GetDestinationPrefixListId() const
Definition Route.h:78
void SetLocalGatewayId(LocalGatewayIdT &&value)
Definition Route.h:207
void SetDestinationPrefixListId(DestinationPrefixListIdT &&value)
Definition Route.h:81
bool CarrierGatewayIdHasBeenSet() const
Definition Route.h:223
const Aws::String & GetLocalGatewayId() const
Definition Route.h:204
Route & WithIpAddress(IpAddressT &&value)
Definition Route.h:361
const Aws::String & GetEgressOnlyInternetGatewayId() const
Definition Route.h:96
const Aws::String & GetDestinationCidrBlock() const
Definition Route.h:42
void SetState(RouteState value)
Definition Route.h:284
const Aws::String & GetInstanceId() const
Definition Route.h:132
bool CoreNetworkArnHasBeenSet() const
Definition Route.h:317
const Aws::String & GetInstanceOwnerId() const
Definition Route.h:150
bool DestinationCidrBlockHasBeenSet() const
Definition Route.h:43
void SetCarrierGatewayId(CarrierGatewayIdT &&value)
Definition Route.h:225
Route & WithNetworkInterfaceId(NetworkInterfaceIdT &&value)
Definition Route.h:248
void SetOrigin(RouteOrigin value)
Definition Route.h:266
const Aws::String & GetCarrierGatewayId() const
Definition Route.h:222
const Aws::String & GetCoreNetworkArn() const
Definition Route.h:316
void SetDestinationCidrBlock(DestinationCidrBlockT &&value)
Definition Route.h:45
void SetNatGatewayId(NatGatewayIdT &&value)
Definition Route.h:171
bool LocalGatewayIdHasBeenSet() const
Definition Route.h:205
void SetOdbNetworkArn(OdbNetworkArnT &&value)
Definition Route.h:337
bool InstanceIdHasBeenSet() const
Definition Route.h:133
RouteOrigin GetOrigin() const
Definition Route.h:264
void SetTransitGatewayId(TransitGatewayIdT &&value)
Definition Route.h:189
bool StateHasBeenSet() const
Definition Route.h:283
const Aws::String & GetNetworkInterfaceId() const
Definition Route.h:240
const Aws::String & GetOdbNetworkArn() const
Definition Route.h:334
Route & WithDestinationIpv6CidrBlock(DestinationIpv6CidrBlockT &&value)
Definition Route.h:68
bool OdbNetworkArnHasBeenSet() const
Definition Route.h:335
Route & WithVpcPeeringConnectionId(VpcPeeringConnectionIdT &&value)
Definition Route.h:306
bool VpcPeeringConnectionIdHasBeenSet() const
Definition Route.h:299
AWS_EC2_API Route(const Aws::Utils::Xml::XmlNode &xmlNode)
bool GatewayIdHasBeenSet() const
Definition Route.h:115
void SetNetworkInterfaceId(NetworkInterfaceIdT &&value)
Definition Route.h:243
void SetInstanceId(InstanceIdT &&value)
Definition Route.h:135
bool InstanceOwnerIdHasBeenSet() const
Definition Route.h:151
RouteState GetState() const
Definition Route.h:282
Route & WithDestinationCidrBlock(DestinationCidrBlockT &&value)
Definition Route.h:50
Route & WithCarrierGatewayId(CarrierGatewayIdT &&value)
Definition Route.h:230
const Aws::String & GetGatewayId() const
Definition Route.h:114
bool EgressOnlyInternetGatewayIdHasBeenSet() const
Definition Route.h:97
AWS_EC2_API void OutputToStream(Aws::OStream &ostream, const char *location, unsigned index, const char *locationValue) const
bool OriginHasBeenSet() const
Definition Route.h:265
bool NatGatewayIdHasBeenSet() const
Definition Route.h:169
AWS_EC2_API Route & operator=(const Aws::Utils::Xml::XmlNode &xmlNode)
Route & WithState(RouteState value)
Definition Route.h:288
void SetIpAddress(IpAddressT &&value)
Definition Route.h:356
void SetInstanceOwnerId(InstanceOwnerIdT &&value)
Definition Route.h:153
bool DestinationPrefixListIdHasBeenSet() const
Definition Route.h:79
bool DestinationIpv6CidrBlockHasBeenSet() const
Definition Route.h:61
const Aws::String & GetIpAddress() const
Definition Route.h:353
void SetVpcPeeringConnectionId(VpcPeeringConnectionIdT &&value)
Definition Route.h:301
const Aws::String & GetDestinationIpv6CidrBlock() const
Definition Route.h:60
bool IpAddressHasBeenSet() const
Definition Route.h:354
void SetDestinationIpv6CidrBlock(DestinationIpv6CidrBlockT &&value)
Definition Route.h:63
Route & WithLocalGatewayId(LocalGatewayIdT &&value)
Definition Route.h:212
Route & WithEgressOnlyInternetGatewayId(EgressOnlyInternetGatewayIdT &&value)
Definition Route.h:104
bool NetworkInterfaceIdHasBeenSet() const
Definition Route.h:241
AWS_EC2_API Route()=default
Route & WithNatGatewayId(NatGatewayIdT &&value)
Definition Route.h:176
Route & WithInstanceOwnerId(InstanceOwnerIdT &&value)
Definition Route.h:158
Route & WithOdbNetworkArn(OdbNetworkArnT &&value)
Definition Route.h:342
const Aws::String & GetNatGatewayId() const
Definition Route.h:168
void SetEgressOnlyInternetGatewayId(EgressOnlyInternetGatewayIdT &&value)
Definition Route.h:99
void SetCoreNetworkArn(CoreNetworkArnT &&value)
Definition Route.h:319
Route & WithDestinationPrefixListId(DestinationPrefixListIdT &&value)
Definition Route.h:86
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::basic_ostream< char, std::char_traits< char > > OStream