/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include #include #include #include #include #include #include #include #include namespace Aws { namespace Utils { namespace Xml { class XmlNode; } // namespace Xml } // namespace Utils namespace EC2 { namespace Model { /** *

Describes a VPN connection.

See Also:

AWS * API Reference

*/ class VpnConnection { public: AWS_EC2_API VpnConnection(); AWS_EC2_API VpnConnection(const Aws::Utils::Xml::XmlNode& xmlNode); AWS_EC2_API VpnConnection& operator=(const Aws::Utils::Xml::XmlNode& xmlNode); AWS_EC2_API void OutputToStream(Aws::OStream& ostream, const char* location, unsigned index, const char* locationValue) const; AWS_EC2_API void OutputToStream(Aws::OStream& oStream, const char* location) const; /** *

The configuration information for the VPN connection's customer gateway (in * the native XML format). This element is always present in the * CreateVpnConnection response; however, it's present in the * DescribeVpnConnections response only if the VPN connection is in the * pending or available state.

*/ inline const Aws::String& GetCustomerGatewayConfiguration() const{ return m_customerGatewayConfiguration; } /** *

The configuration information for the VPN connection's customer gateway (in * the native XML format). This element is always present in the * CreateVpnConnection response; however, it's present in the * DescribeVpnConnections response only if the VPN connection is in the * pending or available state.

*/ inline bool CustomerGatewayConfigurationHasBeenSet() const { return m_customerGatewayConfigurationHasBeenSet; } /** *

The configuration information for the VPN connection's customer gateway (in * the native XML format). This element is always present in the * CreateVpnConnection response; however, it's present in the * DescribeVpnConnections response only if the VPN connection is in the * pending or available state.

*/ inline void SetCustomerGatewayConfiguration(const Aws::String& value) { m_customerGatewayConfigurationHasBeenSet = true; m_customerGatewayConfiguration = value; } /** *

The configuration information for the VPN connection's customer gateway (in * the native XML format). This element is always present in the * CreateVpnConnection response; however, it's present in the * DescribeVpnConnections response only if the VPN connection is in the * pending or available state.

*/ inline void SetCustomerGatewayConfiguration(Aws::String&& value) { m_customerGatewayConfigurationHasBeenSet = true; m_customerGatewayConfiguration = std::move(value); } /** *

The configuration information for the VPN connection's customer gateway (in * the native XML format). This element is always present in the * CreateVpnConnection response; however, it's present in the * DescribeVpnConnections response only if the VPN connection is in the * pending or available state.

*/ inline void SetCustomerGatewayConfiguration(const char* value) { m_customerGatewayConfigurationHasBeenSet = true; m_customerGatewayConfiguration.assign(value); } /** *

The configuration information for the VPN connection's customer gateway (in * the native XML format). This element is always present in the * CreateVpnConnection response; however, it's present in the * DescribeVpnConnections response only if the VPN connection is in the * pending or available state.

*/ inline VpnConnection& WithCustomerGatewayConfiguration(const Aws::String& value) { SetCustomerGatewayConfiguration(value); return *this;} /** *

The configuration information for the VPN connection's customer gateway (in * the native XML format). This element is always present in the * CreateVpnConnection response; however, it's present in the * DescribeVpnConnections response only if the VPN connection is in the * pending or available state.

*/ inline VpnConnection& WithCustomerGatewayConfiguration(Aws::String&& value) { SetCustomerGatewayConfiguration(std::move(value)); return *this;} /** *

The configuration information for the VPN connection's customer gateway (in * the native XML format). This element is always present in the * CreateVpnConnection response; however, it's present in the * DescribeVpnConnections response only if the VPN connection is in the * pending or available state.

*/ inline VpnConnection& WithCustomerGatewayConfiguration(const char* value) { SetCustomerGatewayConfiguration(value); return *this;} /** *

The ID of the customer gateway at your end of the VPN connection.

*/ inline const Aws::String& GetCustomerGatewayId() const{ return m_customerGatewayId; } /** *

The ID of the customer gateway at your end of the VPN connection.

*/ inline bool CustomerGatewayIdHasBeenSet() const { return m_customerGatewayIdHasBeenSet; } /** *

The ID of the customer gateway at your end of the VPN connection.

*/ inline void SetCustomerGatewayId(const Aws::String& value) { m_customerGatewayIdHasBeenSet = true; m_customerGatewayId = value; } /** *

The ID of the customer gateway at your end of the VPN connection.

*/ inline void SetCustomerGatewayId(Aws::String&& value) { m_customerGatewayIdHasBeenSet = true; m_customerGatewayId = std::move(value); } /** *

The ID of the customer gateway at your end of the VPN connection.

*/ inline void SetCustomerGatewayId(const char* value) { m_customerGatewayIdHasBeenSet = true; m_customerGatewayId.assign(value); } /** *

The ID of the customer gateway at your end of the VPN connection.

*/ inline VpnConnection& WithCustomerGatewayId(const Aws::String& value) { SetCustomerGatewayId(value); return *this;} /** *

The ID of the customer gateway at your end of the VPN connection.

*/ inline VpnConnection& WithCustomerGatewayId(Aws::String&& value) { SetCustomerGatewayId(std::move(value)); return *this;} /** *

The ID of the customer gateway at your end of the VPN connection.

*/ inline VpnConnection& WithCustomerGatewayId(const char* value) { SetCustomerGatewayId(value); return *this;} /** *

The category of the VPN connection. A value of VPN indicates an * Amazon Web Services VPN connection. A value of VPN-Classic * indicates an Amazon Web Services Classic VPN connection.

*/ inline const Aws::String& GetCategory() const{ return m_category; } /** *

The category of the VPN connection. A value of VPN indicates an * Amazon Web Services VPN connection. A value of VPN-Classic * indicates an Amazon Web Services Classic VPN connection.

*/ inline bool CategoryHasBeenSet() const { return m_categoryHasBeenSet; } /** *

The category of the VPN connection. A value of VPN indicates an * Amazon Web Services VPN connection. A value of VPN-Classic * indicates an Amazon Web Services Classic VPN connection.

*/ inline void SetCategory(const Aws::String& value) { m_categoryHasBeenSet = true; m_category = value; } /** *

The category of the VPN connection. A value of VPN indicates an * Amazon Web Services VPN connection. A value of VPN-Classic * indicates an Amazon Web Services Classic VPN connection.

*/ inline void SetCategory(Aws::String&& value) { m_categoryHasBeenSet = true; m_category = std::move(value); } /** *

The category of the VPN connection. A value of VPN indicates an * Amazon Web Services VPN connection. A value of VPN-Classic * indicates an Amazon Web Services Classic VPN connection.

*/ inline void SetCategory(const char* value) { m_categoryHasBeenSet = true; m_category.assign(value); } /** *

The category of the VPN connection. A value of VPN indicates an * Amazon Web Services VPN connection. A value of VPN-Classic * indicates an Amazon Web Services Classic VPN connection.

*/ inline VpnConnection& WithCategory(const Aws::String& value) { SetCategory(value); return *this;} /** *

The category of the VPN connection. A value of VPN indicates an * Amazon Web Services VPN connection. A value of VPN-Classic * indicates an Amazon Web Services Classic VPN connection.

*/ inline VpnConnection& WithCategory(Aws::String&& value) { SetCategory(std::move(value)); return *this;} /** *

The category of the VPN connection. A value of VPN indicates an * Amazon Web Services VPN connection. A value of VPN-Classic * indicates an Amazon Web Services Classic VPN connection.

*/ inline VpnConnection& WithCategory(const char* value) { SetCategory(value); return *this;} /** *

The current state of the VPN connection.

*/ inline const VpnState& GetState() const{ return m_state; } /** *

The current state of the VPN connection.

*/ inline bool StateHasBeenSet() const { return m_stateHasBeenSet; } /** *

The current state of the VPN connection.

*/ inline void SetState(const VpnState& value) { m_stateHasBeenSet = true; m_state = value; } /** *

The current state of the VPN connection.

*/ inline void SetState(VpnState&& value) { m_stateHasBeenSet = true; m_state = std::move(value); } /** *

The current state of the VPN connection.

*/ inline VpnConnection& WithState(const VpnState& value) { SetState(value); return *this;} /** *

The current state of the VPN connection.

*/ inline VpnConnection& WithState(VpnState&& value) { SetState(std::move(value)); return *this;} /** *

The type of VPN connection.

*/ inline const GatewayType& GetType() const{ return m_type; } /** *

The type of VPN connection.

*/ inline bool TypeHasBeenSet() const { return m_typeHasBeenSet; } /** *

The type of VPN connection.

*/ inline void SetType(const GatewayType& value) { m_typeHasBeenSet = true; m_type = value; } /** *

The type of VPN connection.

*/ inline void SetType(GatewayType&& value) { m_typeHasBeenSet = true; m_type = std::move(value); } /** *

The type of VPN connection.

*/ inline VpnConnection& WithType(const GatewayType& value) { SetType(value); return *this;} /** *

The type of VPN connection.

*/ inline VpnConnection& WithType(GatewayType&& value) { SetType(std::move(value)); return *this;} /** *

The ID of the VPN connection.

*/ inline const Aws::String& GetVpnConnectionId() const{ return m_vpnConnectionId; } /** *

The ID of the VPN connection.

*/ inline bool VpnConnectionIdHasBeenSet() const { return m_vpnConnectionIdHasBeenSet; } /** *

The ID of the VPN connection.

*/ inline void SetVpnConnectionId(const Aws::String& value) { m_vpnConnectionIdHasBeenSet = true; m_vpnConnectionId = value; } /** *

The ID of the VPN connection.

*/ inline void SetVpnConnectionId(Aws::String&& value) { m_vpnConnectionIdHasBeenSet = true; m_vpnConnectionId = std::move(value); } /** *

The ID of the VPN connection.

*/ inline void SetVpnConnectionId(const char* value) { m_vpnConnectionIdHasBeenSet = true; m_vpnConnectionId.assign(value); } /** *

The ID of the VPN connection.

*/ inline VpnConnection& WithVpnConnectionId(const Aws::String& value) { SetVpnConnectionId(value); return *this;} /** *

The ID of the VPN connection.

*/ inline VpnConnection& WithVpnConnectionId(Aws::String&& value) { SetVpnConnectionId(std::move(value)); return *this;} /** *

The ID of the VPN connection.

*/ inline VpnConnection& WithVpnConnectionId(const char* value) { SetVpnConnectionId(value); return *this;} /** *

The ID of the virtual private gateway at the Amazon Web Services side of the * VPN connection.

*/ inline const Aws::String& GetVpnGatewayId() const{ return m_vpnGatewayId; } /** *

The ID of the virtual private gateway at the Amazon Web Services side of the * VPN connection.

*/ inline bool VpnGatewayIdHasBeenSet() const { return m_vpnGatewayIdHasBeenSet; } /** *

The ID of the virtual private gateway at the Amazon Web Services side of the * VPN connection.

*/ inline void SetVpnGatewayId(const Aws::String& value) { m_vpnGatewayIdHasBeenSet = true; m_vpnGatewayId = value; } /** *

The ID of the virtual private gateway at the Amazon Web Services side of the * VPN connection.

*/ inline void SetVpnGatewayId(Aws::String&& value) { m_vpnGatewayIdHasBeenSet = true; m_vpnGatewayId = std::move(value); } /** *

The ID of the virtual private gateway at the Amazon Web Services side of the * VPN connection.

*/ inline void SetVpnGatewayId(const char* value) { m_vpnGatewayIdHasBeenSet = true; m_vpnGatewayId.assign(value); } /** *

The ID of the virtual private gateway at the Amazon Web Services side of the * VPN connection.

*/ inline VpnConnection& WithVpnGatewayId(const Aws::String& value) { SetVpnGatewayId(value); return *this;} /** *

The ID of the virtual private gateway at the Amazon Web Services side of the * VPN connection.

*/ inline VpnConnection& WithVpnGatewayId(Aws::String&& value) { SetVpnGatewayId(std::move(value)); return *this;} /** *

The ID of the virtual private gateway at the Amazon Web Services side of the * VPN connection.

*/ inline VpnConnection& WithVpnGatewayId(const char* value) { SetVpnGatewayId(value); return *this;} /** *

The ID of the transit gateway associated with the VPN connection.

*/ inline const Aws::String& GetTransitGatewayId() const{ return m_transitGatewayId; } /** *

The ID of the transit gateway associated with the VPN connection.

*/ inline bool TransitGatewayIdHasBeenSet() const { return m_transitGatewayIdHasBeenSet; } /** *

The ID of the transit gateway associated with the VPN connection.

*/ inline void SetTransitGatewayId(const Aws::String& value) { m_transitGatewayIdHasBeenSet = true; m_transitGatewayId = value; } /** *

The ID of the transit gateway associated with the VPN connection.

*/ inline void SetTransitGatewayId(Aws::String&& value) { m_transitGatewayIdHasBeenSet = true; m_transitGatewayId = std::move(value); } /** *

The ID of the transit gateway associated with the VPN connection.

*/ inline void SetTransitGatewayId(const char* value) { m_transitGatewayIdHasBeenSet = true; m_transitGatewayId.assign(value); } /** *

The ID of the transit gateway associated with the VPN connection.

*/ inline VpnConnection& WithTransitGatewayId(const Aws::String& value) { SetTransitGatewayId(value); return *this;} /** *

The ID of the transit gateway associated with the VPN connection.

*/ inline VpnConnection& WithTransitGatewayId(Aws::String&& value) { SetTransitGatewayId(std::move(value)); return *this;} /** *

The ID of the transit gateway associated with the VPN connection.

*/ inline VpnConnection& WithTransitGatewayId(const char* value) { SetTransitGatewayId(value); return *this;} /** *

The ARN of the core network.

*/ inline const Aws::String& GetCoreNetworkArn() const{ return m_coreNetworkArn; } /** *

The ARN of the core network.

*/ inline bool CoreNetworkArnHasBeenSet() const { return m_coreNetworkArnHasBeenSet; } /** *

The ARN of the core network.

*/ inline void SetCoreNetworkArn(const Aws::String& value) { m_coreNetworkArnHasBeenSet = true; m_coreNetworkArn = value; } /** *

The ARN of the core network.

*/ inline void SetCoreNetworkArn(Aws::String&& value) { m_coreNetworkArnHasBeenSet = true; m_coreNetworkArn = std::move(value); } /** *

The ARN of the core network.

*/ inline void SetCoreNetworkArn(const char* value) { m_coreNetworkArnHasBeenSet = true; m_coreNetworkArn.assign(value); } /** *

The ARN of the core network.

*/ inline VpnConnection& WithCoreNetworkArn(const Aws::String& value) { SetCoreNetworkArn(value); return *this;} /** *

The ARN of the core network.

*/ inline VpnConnection& WithCoreNetworkArn(Aws::String&& value) { SetCoreNetworkArn(std::move(value)); return *this;} /** *

The ARN of the core network.

*/ inline VpnConnection& WithCoreNetworkArn(const char* value) { SetCoreNetworkArn(value); return *this;} /** *

The ARN of the core network attachment.

*/ inline const Aws::String& GetCoreNetworkAttachmentArn() const{ return m_coreNetworkAttachmentArn; } /** *

The ARN of the core network attachment.

*/ inline bool CoreNetworkAttachmentArnHasBeenSet() const { return m_coreNetworkAttachmentArnHasBeenSet; } /** *

The ARN of the core network attachment.

*/ inline void SetCoreNetworkAttachmentArn(const Aws::String& value) { m_coreNetworkAttachmentArnHasBeenSet = true; m_coreNetworkAttachmentArn = value; } /** *

The ARN of the core network attachment.

*/ inline void SetCoreNetworkAttachmentArn(Aws::String&& value) { m_coreNetworkAttachmentArnHasBeenSet = true; m_coreNetworkAttachmentArn = std::move(value); } /** *

The ARN of the core network attachment.

*/ inline void SetCoreNetworkAttachmentArn(const char* value) { m_coreNetworkAttachmentArnHasBeenSet = true; m_coreNetworkAttachmentArn.assign(value); } /** *

The ARN of the core network attachment.

*/ inline VpnConnection& WithCoreNetworkAttachmentArn(const Aws::String& value) { SetCoreNetworkAttachmentArn(value); return *this;} /** *

The ARN of the core network attachment.

*/ inline VpnConnection& WithCoreNetworkAttachmentArn(Aws::String&& value) { SetCoreNetworkAttachmentArn(std::move(value)); return *this;} /** *

The ARN of the core network attachment.

*/ inline VpnConnection& WithCoreNetworkAttachmentArn(const char* value) { SetCoreNetworkAttachmentArn(value); return *this;} /** *

The current state of the gateway association.

*/ inline const GatewayAssociationState& GetGatewayAssociationState() const{ return m_gatewayAssociationState; } /** *

The current state of the gateway association.

*/ inline bool GatewayAssociationStateHasBeenSet() const { return m_gatewayAssociationStateHasBeenSet; } /** *

The current state of the gateway association.

*/ inline void SetGatewayAssociationState(const GatewayAssociationState& value) { m_gatewayAssociationStateHasBeenSet = true; m_gatewayAssociationState = value; } /** *

The current state of the gateway association.

*/ inline void SetGatewayAssociationState(GatewayAssociationState&& value) { m_gatewayAssociationStateHasBeenSet = true; m_gatewayAssociationState = std::move(value); } /** *

The current state of the gateway association.

*/ inline VpnConnection& WithGatewayAssociationState(const GatewayAssociationState& value) { SetGatewayAssociationState(value); return *this;} /** *

The current state of the gateway association.

*/ inline VpnConnection& WithGatewayAssociationState(GatewayAssociationState&& value) { SetGatewayAssociationState(std::move(value)); return *this;} /** *

The VPN connection options.

*/ inline const VpnConnectionOptions& GetOptions() const{ return m_options; } /** *

The VPN connection options.

*/ inline bool OptionsHasBeenSet() const { return m_optionsHasBeenSet; } /** *

The VPN connection options.

*/ inline void SetOptions(const VpnConnectionOptions& value) { m_optionsHasBeenSet = true; m_options = value; } /** *

The VPN connection options.

*/ inline void SetOptions(VpnConnectionOptions&& value) { m_optionsHasBeenSet = true; m_options = std::move(value); } /** *

The VPN connection options.

*/ inline VpnConnection& WithOptions(const VpnConnectionOptions& value) { SetOptions(value); return *this;} /** *

The VPN connection options.

*/ inline VpnConnection& WithOptions(VpnConnectionOptions&& value) { SetOptions(std::move(value)); return *this;} /** *

The static routes associated with the VPN connection.

*/ inline const Aws::Vector& GetRoutes() const{ return m_routes; } /** *

The static routes associated with the VPN connection.

*/ inline bool RoutesHasBeenSet() const { return m_routesHasBeenSet; } /** *

The static routes associated with the VPN connection.

*/ inline void SetRoutes(const Aws::Vector& value) { m_routesHasBeenSet = true; m_routes = value; } /** *

The static routes associated with the VPN connection.

*/ inline void SetRoutes(Aws::Vector&& value) { m_routesHasBeenSet = true; m_routes = std::move(value); } /** *

The static routes associated with the VPN connection.

*/ inline VpnConnection& WithRoutes(const Aws::Vector& value) { SetRoutes(value); return *this;} /** *

The static routes associated with the VPN connection.

*/ inline VpnConnection& WithRoutes(Aws::Vector&& value) { SetRoutes(std::move(value)); return *this;} /** *

The static routes associated with the VPN connection.

*/ inline VpnConnection& AddRoutes(const VpnStaticRoute& value) { m_routesHasBeenSet = true; m_routes.push_back(value); return *this; } /** *

The static routes associated with the VPN connection.

*/ inline VpnConnection& AddRoutes(VpnStaticRoute&& value) { m_routesHasBeenSet = true; m_routes.push_back(std::move(value)); return *this; } /** *

Any tags assigned to the VPN connection.

*/ inline const Aws::Vector& GetTags() const{ return m_tags; } /** *

Any tags assigned to the VPN connection.

*/ inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; } /** *

Any tags assigned to the VPN connection.

*/ inline void SetTags(const Aws::Vector& value) { m_tagsHasBeenSet = true; m_tags = value; } /** *

Any tags assigned to the VPN connection.

*/ inline void SetTags(Aws::Vector&& value) { m_tagsHasBeenSet = true; m_tags = std::move(value); } /** *

Any tags assigned to the VPN connection.

*/ inline VpnConnection& WithTags(const Aws::Vector& value) { SetTags(value); return *this;} /** *

Any tags assigned to the VPN connection.

*/ inline VpnConnection& WithTags(Aws::Vector&& value) { SetTags(std::move(value)); return *this;} /** *

Any tags assigned to the VPN connection.

*/ inline VpnConnection& AddTags(const Tag& value) { m_tagsHasBeenSet = true; m_tags.push_back(value); return *this; } /** *

Any tags assigned to the VPN connection.

*/ inline VpnConnection& AddTags(Tag&& value) { m_tagsHasBeenSet = true; m_tags.push_back(std::move(value)); return *this; } /** *

Information about the VPN tunnel.

*/ inline const Aws::Vector& GetVgwTelemetry() const{ return m_vgwTelemetry; } /** *

Information about the VPN tunnel.

*/ inline bool VgwTelemetryHasBeenSet() const { return m_vgwTelemetryHasBeenSet; } /** *

Information about the VPN tunnel.

*/ inline void SetVgwTelemetry(const Aws::Vector& value) { m_vgwTelemetryHasBeenSet = true; m_vgwTelemetry = value; } /** *

Information about the VPN tunnel.

*/ inline void SetVgwTelemetry(Aws::Vector&& value) { m_vgwTelemetryHasBeenSet = true; m_vgwTelemetry = std::move(value); } /** *

Information about the VPN tunnel.

*/ inline VpnConnection& WithVgwTelemetry(const Aws::Vector& value) { SetVgwTelemetry(value); return *this;} /** *

Information about the VPN tunnel.

*/ inline VpnConnection& WithVgwTelemetry(Aws::Vector&& value) { SetVgwTelemetry(std::move(value)); return *this;} /** *

Information about the VPN tunnel.

*/ inline VpnConnection& AddVgwTelemetry(const VgwTelemetry& value) { m_vgwTelemetryHasBeenSet = true; m_vgwTelemetry.push_back(value); return *this; } /** *

Information about the VPN tunnel.

*/ inline VpnConnection& AddVgwTelemetry(VgwTelemetry&& value) { m_vgwTelemetryHasBeenSet = true; m_vgwTelemetry.push_back(std::move(value)); return *this; } private: Aws::String m_customerGatewayConfiguration; bool m_customerGatewayConfigurationHasBeenSet = false; Aws::String m_customerGatewayId; bool m_customerGatewayIdHasBeenSet = false; Aws::String m_category; bool m_categoryHasBeenSet = false; VpnState m_state; bool m_stateHasBeenSet = false; GatewayType m_type; bool m_typeHasBeenSet = false; Aws::String m_vpnConnectionId; bool m_vpnConnectionIdHasBeenSet = false; Aws::String m_vpnGatewayId; bool m_vpnGatewayIdHasBeenSet = false; Aws::String m_transitGatewayId; bool m_transitGatewayIdHasBeenSet = false; Aws::String m_coreNetworkArn; bool m_coreNetworkArnHasBeenSet = false; Aws::String m_coreNetworkAttachmentArn; bool m_coreNetworkAttachmentArnHasBeenSet = false; GatewayAssociationState m_gatewayAssociationState; bool m_gatewayAssociationStateHasBeenSet = false; VpnConnectionOptions m_options; bool m_optionsHasBeenSet = false; Aws::Vector m_routes; bool m_routesHasBeenSet = false; Aws::Vector m_tags; bool m_tagsHasBeenSet = false; Aws::Vector m_vgwTelemetry; bool m_vgwTelemetryHasBeenSet = false; }; } // namespace Model } // namespace EC2 } // namespace Aws