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

Information about a BGP peer.

See Also:

AWS * API Reference

*/ class BGPPeer { public: AWS_DIRECTCONNECT_API BGPPeer(); AWS_DIRECTCONNECT_API BGPPeer(Aws::Utils::Json::JsonView jsonValue); AWS_DIRECTCONNECT_API BGPPeer& operator=(Aws::Utils::Json::JsonView jsonValue); AWS_DIRECTCONNECT_API Aws::Utils::Json::JsonValue Jsonize() const; /** *

The ID of the BGP peer.

*/ inline const Aws::String& GetBgpPeerId() const{ return m_bgpPeerId; } /** *

The ID of the BGP peer.

*/ inline bool BgpPeerIdHasBeenSet() const { return m_bgpPeerIdHasBeenSet; } /** *

The ID of the BGP peer.

*/ inline void SetBgpPeerId(const Aws::String& value) { m_bgpPeerIdHasBeenSet = true; m_bgpPeerId = value; } /** *

The ID of the BGP peer.

*/ inline void SetBgpPeerId(Aws::String&& value) { m_bgpPeerIdHasBeenSet = true; m_bgpPeerId = std::move(value); } /** *

The ID of the BGP peer.

*/ inline void SetBgpPeerId(const char* value) { m_bgpPeerIdHasBeenSet = true; m_bgpPeerId.assign(value); } /** *

The ID of the BGP peer.

*/ inline BGPPeer& WithBgpPeerId(const Aws::String& value) { SetBgpPeerId(value); return *this;} /** *

The ID of the BGP peer.

*/ inline BGPPeer& WithBgpPeerId(Aws::String&& value) { SetBgpPeerId(std::move(value)); return *this;} /** *

The ID of the BGP peer.

*/ inline BGPPeer& WithBgpPeerId(const char* value) { SetBgpPeerId(value); return *this;} /** *

The autonomous system (AS) number for Border Gateway Protocol (BGP) * configuration.

*/ inline int GetAsn() const{ return m_asn; } /** *

The autonomous system (AS) number for Border Gateway Protocol (BGP) * configuration.

*/ inline bool AsnHasBeenSet() const { return m_asnHasBeenSet; } /** *

The autonomous system (AS) number for Border Gateway Protocol (BGP) * configuration.

*/ inline void SetAsn(int value) { m_asnHasBeenSet = true; m_asn = value; } /** *

The autonomous system (AS) number for Border Gateway Protocol (BGP) * configuration.

*/ inline BGPPeer& WithAsn(int value) { SetAsn(value); return *this;} /** *

The authentication key for BGP configuration. This string has a minimum * length of 6 characters and and a maximun lenth of 80 characters.

*/ inline const Aws::String& GetAuthKey() const{ return m_authKey; } /** *

The authentication key for BGP configuration. This string has a minimum * length of 6 characters and and a maximun lenth of 80 characters.

*/ inline bool AuthKeyHasBeenSet() const { return m_authKeyHasBeenSet; } /** *

The authentication key for BGP configuration. This string has a minimum * length of 6 characters and and a maximun lenth of 80 characters.

*/ inline void SetAuthKey(const Aws::String& value) { m_authKeyHasBeenSet = true; m_authKey = value; } /** *

The authentication key for BGP configuration. This string has a minimum * length of 6 characters and and a maximun lenth of 80 characters.

*/ inline void SetAuthKey(Aws::String&& value) { m_authKeyHasBeenSet = true; m_authKey = std::move(value); } /** *

The authentication key for BGP configuration. This string has a minimum * length of 6 characters and and a maximun lenth of 80 characters.

*/ inline void SetAuthKey(const char* value) { m_authKeyHasBeenSet = true; m_authKey.assign(value); } /** *

The authentication key for BGP configuration. This string has a minimum * length of 6 characters and and a maximun lenth of 80 characters.

*/ inline BGPPeer& WithAuthKey(const Aws::String& value) { SetAuthKey(value); return *this;} /** *

The authentication key for BGP configuration. This string has a minimum * length of 6 characters and and a maximun lenth of 80 characters.

*/ inline BGPPeer& WithAuthKey(Aws::String&& value) { SetAuthKey(std::move(value)); return *this;} /** *

The authentication key for BGP configuration. This string has a minimum * length of 6 characters and and a maximun lenth of 80 characters.

*/ inline BGPPeer& WithAuthKey(const char* value) { SetAuthKey(value); return *this;} /** *

The address family for the BGP peer.

*/ inline const AddressFamily& GetAddressFamily() const{ return m_addressFamily; } /** *

The address family for the BGP peer.

*/ inline bool AddressFamilyHasBeenSet() const { return m_addressFamilyHasBeenSet; } /** *

The address family for the BGP peer.

*/ inline void SetAddressFamily(const AddressFamily& value) { m_addressFamilyHasBeenSet = true; m_addressFamily = value; } /** *

The address family for the BGP peer.

*/ inline void SetAddressFamily(AddressFamily&& value) { m_addressFamilyHasBeenSet = true; m_addressFamily = std::move(value); } /** *

The address family for the BGP peer.

*/ inline BGPPeer& WithAddressFamily(const AddressFamily& value) { SetAddressFamily(value); return *this;} /** *

The address family for the BGP peer.

*/ inline BGPPeer& WithAddressFamily(AddressFamily&& value) { SetAddressFamily(std::move(value)); return *this;} /** *

The IP address assigned to the Amazon interface.

*/ inline const Aws::String& GetAmazonAddress() const{ return m_amazonAddress; } /** *

The IP address assigned to the Amazon interface.

*/ inline bool AmazonAddressHasBeenSet() const { return m_amazonAddressHasBeenSet; } /** *

The IP address assigned to the Amazon interface.

*/ inline void SetAmazonAddress(const Aws::String& value) { m_amazonAddressHasBeenSet = true; m_amazonAddress = value; } /** *

The IP address assigned to the Amazon interface.

*/ inline void SetAmazonAddress(Aws::String&& value) { m_amazonAddressHasBeenSet = true; m_amazonAddress = std::move(value); } /** *

The IP address assigned to the Amazon interface.

*/ inline void SetAmazonAddress(const char* value) { m_amazonAddressHasBeenSet = true; m_amazonAddress.assign(value); } /** *

The IP address assigned to the Amazon interface.

*/ inline BGPPeer& WithAmazonAddress(const Aws::String& value) { SetAmazonAddress(value); return *this;} /** *

The IP address assigned to the Amazon interface.

*/ inline BGPPeer& WithAmazonAddress(Aws::String&& value) { SetAmazonAddress(std::move(value)); return *this;} /** *

The IP address assigned to the Amazon interface.

*/ inline BGPPeer& WithAmazonAddress(const char* value) { SetAmazonAddress(value); return *this;} /** *

The IP address assigned to the customer interface.

*/ inline const Aws::String& GetCustomerAddress() const{ return m_customerAddress; } /** *

The IP address assigned to the customer interface.

*/ inline bool CustomerAddressHasBeenSet() const { return m_customerAddressHasBeenSet; } /** *

The IP address assigned to the customer interface.

*/ inline void SetCustomerAddress(const Aws::String& value) { m_customerAddressHasBeenSet = true; m_customerAddress = value; } /** *

The IP address assigned to the customer interface.

*/ inline void SetCustomerAddress(Aws::String&& value) { m_customerAddressHasBeenSet = true; m_customerAddress = std::move(value); } /** *

The IP address assigned to the customer interface.

*/ inline void SetCustomerAddress(const char* value) { m_customerAddressHasBeenSet = true; m_customerAddress.assign(value); } /** *

The IP address assigned to the customer interface.

*/ inline BGPPeer& WithCustomerAddress(const Aws::String& value) { SetCustomerAddress(value); return *this;} /** *

The IP address assigned to the customer interface.

*/ inline BGPPeer& WithCustomerAddress(Aws::String&& value) { SetCustomerAddress(std::move(value)); return *this;} /** *

The IP address assigned to the customer interface.

*/ inline BGPPeer& WithCustomerAddress(const char* value) { SetCustomerAddress(value); return *this;} /** *

The state of the BGP peer. The following are the possible values:

    *
  • verifying: The BGP peering addresses or ASN require * validation before the BGP peer can be created. This state applies only to public * virtual interfaces.

  • pending: The BGP peer is * created, and remains in this state until it is ready to be established.

    *
  • available: The BGP peer is ready to be * established.

  • deleting: The BGP peer is being * deleted.

  • deleted: The BGP peer is deleted and * cannot be established.

*/ inline const BGPPeerState& GetBgpPeerState() const{ return m_bgpPeerState; } /** *

The state of the BGP peer. The following are the possible values:

    *
  • verifying: The BGP peering addresses or ASN require * validation before the BGP peer can be created. This state applies only to public * virtual interfaces.

  • pending: The BGP peer is * created, and remains in this state until it is ready to be established.

    *
  • available: The BGP peer is ready to be * established.

  • deleting: The BGP peer is being * deleted.

  • deleted: The BGP peer is deleted and * cannot be established.

*/ inline bool BgpPeerStateHasBeenSet() const { return m_bgpPeerStateHasBeenSet; } /** *

The state of the BGP peer. The following are the possible values:

    *
  • verifying: The BGP peering addresses or ASN require * validation before the BGP peer can be created. This state applies only to public * virtual interfaces.

  • pending: The BGP peer is * created, and remains in this state until it is ready to be established.

    *
  • available: The BGP peer is ready to be * established.

  • deleting: The BGP peer is being * deleted.

  • deleted: The BGP peer is deleted and * cannot be established.

*/ inline void SetBgpPeerState(const BGPPeerState& value) { m_bgpPeerStateHasBeenSet = true; m_bgpPeerState = value; } /** *

The state of the BGP peer. The following are the possible values:

    *
  • verifying: The BGP peering addresses or ASN require * validation before the BGP peer can be created. This state applies only to public * virtual interfaces.

  • pending: The BGP peer is * created, and remains in this state until it is ready to be established.

    *
  • available: The BGP peer is ready to be * established.

  • deleting: The BGP peer is being * deleted.

  • deleted: The BGP peer is deleted and * cannot be established.

*/ inline void SetBgpPeerState(BGPPeerState&& value) { m_bgpPeerStateHasBeenSet = true; m_bgpPeerState = std::move(value); } /** *

The state of the BGP peer. The following are the possible values:

    *
  • verifying: The BGP peering addresses or ASN require * validation before the BGP peer can be created. This state applies only to public * virtual interfaces.

  • pending: The BGP peer is * created, and remains in this state until it is ready to be established.

    *
  • available: The BGP peer is ready to be * established.

  • deleting: The BGP peer is being * deleted.

  • deleted: The BGP peer is deleted and * cannot be established.

*/ inline BGPPeer& WithBgpPeerState(const BGPPeerState& value) { SetBgpPeerState(value); return *this;} /** *

The state of the BGP peer. The following are the possible values:

    *
  • verifying: The BGP peering addresses or ASN require * validation before the BGP peer can be created. This state applies only to public * virtual interfaces.

  • pending: The BGP peer is * created, and remains in this state until it is ready to be established.

    *
  • available: The BGP peer is ready to be * established.

  • deleting: The BGP peer is being * deleted.

  • deleted: The BGP peer is deleted and * cannot be established.

*/ inline BGPPeer& WithBgpPeerState(BGPPeerState&& value) { SetBgpPeerState(std::move(value)); return *this;} /** *

The status of the BGP peer. The following are the possible values:

    *
  • up: The BGP peer is established. This state does not * indicate the state of the routing function. Ensure that you are receiving routes * over the BGP session.

  • down: The BGP peer is * down.

  • unknown: The BGP peer status is not * available.

*/ inline const BGPStatus& GetBgpStatus() const{ return m_bgpStatus; } /** *

The status of the BGP peer. The following are the possible values:

    *
  • up: The BGP peer is established. This state does not * indicate the state of the routing function. Ensure that you are receiving routes * over the BGP session.

  • down: The BGP peer is * down.

  • unknown: The BGP peer status is not * available.

*/ inline bool BgpStatusHasBeenSet() const { return m_bgpStatusHasBeenSet; } /** *

The status of the BGP peer. The following are the possible values:

    *
  • up: The BGP peer is established. This state does not * indicate the state of the routing function. Ensure that you are receiving routes * over the BGP session.

  • down: The BGP peer is * down.

  • unknown: The BGP peer status is not * available.

*/ inline void SetBgpStatus(const BGPStatus& value) { m_bgpStatusHasBeenSet = true; m_bgpStatus = value; } /** *

The status of the BGP peer. The following are the possible values:

    *
  • up: The BGP peer is established. This state does not * indicate the state of the routing function. Ensure that you are receiving routes * over the BGP session.

  • down: The BGP peer is * down.

  • unknown: The BGP peer status is not * available.

*/ inline void SetBgpStatus(BGPStatus&& value) { m_bgpStatusHasBeenSet = true; m_bgpStatus = std::move(value); } /** *

The status of the BGP peer. The following are the possible values:

    *
  • up: The BGP peer is established. This state does not * indicate the state of the routing function. Ensure that you are receiving routes * over the BGP session.

  • down: The BGP peer is * down.

  • unknown: The BGP peer status is not * available.

*/ inline BGPPeer& WithBgpStatus(const BGPStatus& value) { SetBgpStatus(value); return *this;} /** *

The status of the BGP peer. The following are the possible values:

    *
  • up: The BGP peer is established. This state does not * indicate the state of the routing function. Ensure that you are receiving routes * over the BGP session.

  • down: The BGP peer is * down.

  • unknown: The BGP peer status is not * available.

*/ inline BGPPeer& WithBgpStatus(BGPStatus&& value) { SetBgpStatus(std::move(value)); return *this;} /** *

The Direct Connect endpoint that terminates the BGP peer.

*/ inline const Aws::String& GetAwsDeviceV2() const{ return m_awsDeviceV2; } /** *

The Direct Connect endpoint that terminates the BGP peer.

*/ inline bool AwsDeviceV2HasBeenSet() const { return m_awsDeviceV2HasBeenSet; } /** *

The Direct Connect endpoint that terminates the BGP peer.

*/ inline void SetAwsDeviceV2(const Aws::String& value) { m_awsDeviceV2HasBeenSet = true; m_awsDeviceV2 = value; } /** *

The Direct Connect endpoint that terminates the BGP peer.

*/ inline void SetAwsDeviceV2(Aws::String&& value) { m_awsDeviceV2HasBeenSet = true; m_awsDeviceV2 = std::move(value); } /** *

The Direct Connect endpoint that terminates the BGP peer.

*/ inline void SetAwsDeviceV2(const char* value) { m_awsDeviceV2HasBeenSet = true; m_awsDeviceV2.assign(value); } /** *

The Direct Connect endpoint that terminates the BGP peer.

*/ inline BGPPeer& WithAwsDeviceV2(const Aws::String& value) { SetAwsDeviceV2(value); return *this;} /** *

The Direct Connect endpoint that terminates the BGP peer.

*/ inline BGPPeer& WithAwsDeviceV2(Aws::String&& value) { SetAwsDeviceV2(std::move(value)); return *this;} /** *

The Direct Connect endpoint that terminates the BGP peer.

*/ inline BGPPeer& WithAwsDeviceV2(const char* value) { SetAwsDeviceV2(value); return *this;} /** *

The Direct Connect endpoint that terminates the logical connection. This * device might be different than the device that terminates the physical * connection.

*/ inline const Aws::String& GetAwsLogicalDeviceId() const{ return m_awsLogicalDeviceId; } /** *

The Direct Connect endpoint that terminates the logical connection. This * device might be different than the device that terminates the physical * connection.

*/ inline bool AwsLogicalDeviceIdHasBeenSet() const { return m_awsLogicalDeviceIdHasBeenSet; } /** *

The Direct Connect endpoint that terminates the logical connection. This * device might be different than the device that terminates the physical * connection.

*/ inline void SetAwsLogicalDeviceId(const Aws::String& value) { m_awsLogicalDeviceIdHasBeenSet = true; m_awsLogicalDeviceId = value; } /** *

The Direct Connect endpoint that terminates the logical connection. This * device might be different than the device that terminates the physical * connection.

*/ inline void SetAwsLogicalDeviceId(Aws::String&& value) { m_awsLogicalDeviceIdHasBeenSet = true; m_awsLogicalDeviceId = std::move(value); } /** *

The Direct Connect endpoint that terminates the logical connection. This * device might be different than the device that terminates the physical * connection.

*/ inline void SetAwsLogicalDeviceId(const char* value) { m_awsLogicalDeviceIdHasBeenSet = true; m_awsLogicalDeviceId.assign(value); } /** *

The Direct Connect endpoint that terminates the logical connection. This * device might be different than the device that terminates the physical * connection.

*/ inline BGPPeer& WithAwsLogicalDeviceId(const Aws::String& value) { SetAwsLogicalDeviceId(value); return *this;} /** *

The Direct Connect endpoint that terminates the logical connection. This * device might be different than the device that terminates the physical * connection.

*/ inline BGPPeer& WithAwsLogicalDeviceId(Aws::String&& value) { SetAwsLogicalDeviceId(std::move(value)); return *this;} /** *

The Direct Connect endpoint that terminates the logical connection. This * device might be different than the device that terminates the physical * connection.

*/ inline BGPPeer& WithAwsLogicalDeviceId(const char* value) { SetAwsLogicalDeviceId(value); return *this;} private: Aws::String m_bgpPeerId; bool m_bgpPeerIdHasBeenSet = false; int m_asn; bool m_asnHasBeenSet = false; Aws::String m_authKey; bool m_authKeyHasBeenSet = false; AddressFamily m_addressFamily; bool m_addressFamilyHasBeenSet = false; Aws::String m_amazonAddress; bool m_amazonAddressHasBeenSet = false; Aws::String m_customerAddress; bool m_customerAddressHasBeenSet = false; BGPPeerState m_bgpPeerState; bool m_bgpPeerStateHasBeenSet = false; BGPStatus m_bgpStatus; bool m_bgpStatusHasBeenSet = false; Aws::String m_awsDeviceV2; bool m_awsDeviceV2HasBeenSet = false; Aws::String m_awsLogicalDeviceId; bool m_awsLogicalDeviceIdHasBeenSet = false; }; } // namespace Model } // namespace DirectConnect } // namespace Aws