/** * 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 EC2 { namespace Model { /** */ class AllocateIpamPoolCidrRequest : public EC2Request { public: AWS_EC2_API AllocateIpamPoolCidrRequest(); // Service request name is the Operation name which will send this request out, // each operation should has unique request name, so that we can get operation's name from this request. // Note: this is not true for response, multiple operations may have the same response name, // so we can not get operation's name from response. inline virtual const char* GetServiceRequestName() const override { return "AllocateIpamPoolCidr"; } AWS_EC2_API Aws::String SerializePayload() const override; protected: AWS_EC2_API void DumpBodyToUrl(Aws::Http::URI& uri ) const override; public: /** *

A check for whether you have the required permissions for the action without * actually making the request and provides an error response. If you have the * required permissions, the error response is DryRunOperation. * Otherwise, it is UnauthorizedOperation.

*/ inline bool GetDryRun() const{ return m_dryRun; } /** *

A check for whether you have the required permissions for the action without * actually making the request and provides an error response. If you have the * required permissions, the error response is DryRunOperation. * Otherwise, it is UnauthorizedOperation.

*/ inline bool DryRunHasBeenSet() const { return m_dryRunHasBeenSet; } /** *

A check for whether you have the required permissions for the action without * actually making the request and provides an error response. If you have the * required permissions, the error response is DryRunOperation. * Otherwise, it is UnauthorizedOperation.

*/ inline void SetDryRun(bool value) { m_dryRunHasBeenSet = true; m_dryRun = value; } /** *

A check for whether you have the required permissions for the action without * actually making the request and provides an error response. If you have the * required permissions, the error response is DryRunOperation. * Otherwise, it is UnauthorizedOperation.

*/ inline AllocateIpamPoolCidrRequest& WithDryRun(bool value) { SetDryRun(value); return *this;} /** *

The ID of the IPAM pool from which you would like to allocate a CIDR.

*/ inline const Aws::String& GetIpamPoolId() const{ return m_ipamPoolId; } /** *

The ID of the IPAM pool from which you would like to allocate a CIDR.

*/ inline bool IpamPoolIdHasBeenSet() const { return m_ipamPoolIdHasBeenSet; } /** *

The ID of the IPAM pool from which you would like to allocate a CIDR.

*/ inline void SetIpamPoolId(const Aws::String& value) { m_ipamPoolIdHasBeenSet = true; m_ipamPoolId = value; } /** *

The ID of the IPAM pool from which you would like to allocate a CIDR.

*/ inline void SetIpamPoolId(Aws::String&& value) { m_ipamPoolIdHasBeenSet = true; m_ipamPoolId = std::move(value); } /** *

The ID of the IPAM pool from which you would like to allocate a CIDR.

*/ inline void SetIpamPoolId(const char* value) { m_ipamPoolIdHasBeenSet = true; m_ipamPoolId.assign(value); } /** *

The ID of the IPAM pool from which you would like to allocate a CIDR.

*/ inline AllocateIpamPoolCidrRequest& WithIpamPoolId(const Aws::String& value) { SetIpamPoolId(value); return *this;} /** *

The ID of the IPAM pool from which you would like to allocate a CIDR.

*/ inline AllocateIpamPoolCidrRequest& WithIpamPoolId(Aws::String&& value) { SetIpamPoolId(std::move(value)); return *this;} /** *

The ID of the IPAM pool from which you would like to allocate a CIDR.

*/ inline AllocateIpamPoolCidrRequest& WithIpamPoolId(const char* value) { SetIpamPoolId(value); return *this;} /** *

The CIDR you would like to allocate from the IPAM pool. Note the * following:

  • If there is no DefaultNetmaskLength allocation rule * set on the pool, you must specify either the NetmaskLength or the CIDR.

    *
  • If the DefaultNetmaskLength allocation rule is set on the pool, * you can specify either the NetmaskLength or the CIDR and the * DefaultNetmaskLength allocation rule will be ignored.

*

Possible values: Any available IPv4 or IPv6 CIDR.

*/ inline const Aws::String& GetCidr() const{ return m_cidr; } /** *

The CIDR you would like to allocate from the IPAM pool. Note the * following:

  • If there is no DefaultNetmaskLength allocation rule * set on the pool, you must specify either the NetmaskLength or the CIDR.

    *
  • If the DefaultNetmaskLength allocation rule is set on the pool, * you can specify either the NetmaskLength or the CIDR and the * DefaultNetmaskLength allocation rule will be ignored.

*

Possible values: Any available IPv4 or IPv6 CIDR.

*/ inline bool CidrHasBeenSet() const { return m_cidrHasBeenSet; } /** *

The CIDR you would like to allocate from the IPAM pool. Note the * following:

  • If there is no DefaultNetmaskLength allocation rule * set on the pool, you must specify either the NetmaskLength or the CIDR.

    *
  • If the DefaultNetmaskLength allocation rule is set on the pool, * you can specify either the NetmaskLength or the CIDR and the * DefaultNetmaskLength allocation rule will be ignored.

*

Possible values: Any available IPv4 or IPv6 CIDR.

*/ inline void SetCidr(const Aws::String& value) { m_cidrHasBeenSet = true; m_cidr = value; } /** *

The CIDR you would like to allocate from the IPAM pool. Note the * following:

  • If there is no DefaultNetmaskLength allocation rule * set on the pool, you must specify either the NetmaskLength or the CIDR.

    *
  • If the DefaultNetmaskLength allocation rule is set on the pool, * you can specify either the NetmaskLength or the CIDR and the * DefaultNetmaskLength allocation rule will be ignored.

*

Possible values: Any available IPv4 or IPv6 CIDR.

*/ inline void SetCidr(Aws::String&& value) { m_cidrHasBeenSet = true; m_cidr = std::move(value); } /** *

The CIDR you would like to allocate from the IPAM pool. Note the * following:

  • If there is no DefaultNetmaskLength allocation rule * set on the pool, you must specify either the NetmaskLength or the CIDR.

    *
  • If the DefaultNetmaskLength allocation rule is set on the pool, * you can specify either the NetmaskLength or the CIDR and the * DefaultNetmaskLength allocation rule will be ignored.

*

Possible values: Any available IPv4 or IPv6 CIDR.

*/ inline void SetCidr(const char* value) { m_cidrHasBeenSet = true; m_cidr.assign(value); } /** *

The CIDR you would like to allocate from the IPAM pool. Note the * following:

  • If there is no DefaultNetmaskLength allocation rule * set on the pool, you must specify either the NetmaskLength or the CIDR.

    *
  • If the DefaultNetmaskLength allocation rule is set on the pool, * you can specify either the NetmaskLength or the CIDR and the * DefaultNetmaskLength allocation rule will be ignored.

*

Possible values: Any available IPv4 or IPv6 CIDR.

*/ inline AllocateIpamPoolCidrRequest& WithCidr(const Aws::String& value) { SetCidr(value); return *this;} /** *

The CIDR you would like to allocate from the IPAM pool. Note the * following:

  • If there is no DefaultNetmaskLength allocation rule * set on the pool, you must specify either the NetmaskLength or the CIDR.

    *
  • If the DefaultNetmaskLength allocation rule is set on the pool, * you can specify either the NetmaskLength or the CIDR and the * DefaultNetmaskLength allocation rule will be ignored.

*

Possible values: Any available IPv4 or IPv6 CIDR.

*/ inline AllocateIpamPoolCidrRequest& WithCidr(Aws::String&& value) { SetCidr(std::move(value)); return *this;} /** *

The CIDR you would like to allocate from the IPAM pool. Note the * following:

  • If there is no DefaultNetmaskLength allocation rule * set on the pool, you must specify either the NetmaskLength or the CIDR.

    *
  • If the DefaultNetmaskLength allocation rule is set on the pool, * you can specify either the NetmaskLength or the CIDR and the * DefaultNetmaskLength allocation rule will be ignored.

*

Possible values: Any available IPv4 or IPv6 CIDR.

*/ inline AllocateIpamPoolCidrRequest& WithCidr(const char* value) { SetCidr(value); return *this;} /** *

The netmask length of the CIDR you would like to allocate from the IPAM pool. * Note the following:

  • If there is no DefaultNetmaskLength * allocation rule set on the pool, you must specify either the NetmaskLength or * the CIDR.

  • If the DefaultNetmaskLength allocation rule is set * on the pool, you can specify either the NetmaskLength or the CIDR and the * DefaultNetmaskLength allocation rule will be ignored.

*

Possible netmask lengths for IPv4 addresses are 0 - 32. Possible netmask * lengths for IPv6 addresses are 0 - 128.

*/ inline int GetNetmaskLength() const{ return m_netmaskLength; } /** *

The netmask length of the CIDR you would like to allocate from the IPAM pool. * Note the following:

  • If there is no DefaultNetmaskLength * allocation rule set on the pool, you must specify either the NetmaskLength or * the CIDR.

  • If the DefaultNetmaskLength allocation rule is set * on the pool, you can specify either the NetmaskLength or the CIDR and the * DefaultNetmaskLength allocation rule will be ignored.

*

Possible netmask lengths for IPv4 addresses are 0 - 32. Possible netmask * lengths for IPv6 addresses are 0 - 128.

*/ inline bool NetmaskLengthHasBeenSet() const { return m_netmaskLengthHasBeenSet; } /** *

The netmask length of the CIDR you would like to allocate from the IPAM pool. * Note the following:

  • If there is no DefaultNetmaskLength * allocation rule set on the pool, you must specify either the NetmaskLength or * the CIDR.

  • If the DefaultNetmaskLength allocation rule is set * on the pool, you can specify either the NetmaskLength or the CIDR and the * DefaultNetmaskLength allocation rule will be ignored.

*

Possible netmask lengths for IPv4 addresses are 0 - 32. Possible netmask * lengths for IPv6 addresses are 0 - 128.

*/ inline void SetNetmaskLength(int value) { m_netmaskLengthHasBeenSet = true; m_netmaskLength = value; } /** *

The netmask length of the CIDR you would like to allocate from the IPAM pool. * Note the following:

  • If there is no DefaultNetmaskLength * allocation rule set on the pool, you must specify either the NetmaskLength or * the CIDR.

  • If the DefaultNetmaskLength allocation rule is set * on the pool, you can specify either the NetmaskLength or the CIDR and the * DefaultNetmaskLength allocation rule will be ignored.

*

Possible netmask lengths for IPv4 addresses are 0 - 32. Possible netmask * lengths for IPv6 addresses are 0 - 128.

*/ inline AllocateIpamPoolCidrRequest& WithNetmaskLength(int value) { SetNetmaskLength(value); return *this;} /** *

A unique, case-sensitive identifier that you provide to ensure the * idempotency of the request. For more information, see Ensuring * Idempotency.

*/ inline const Aws::String& GetClientToken() const{ return m_clientToken; } /** *

A unique, case-sensitive identifier that you provide to ensure the * idempotency of the request. For more information, see Ensuring * Idempotency.

*/ inline bool ClientTokenHasBeenSet() const { return m_clientTokenHasBeenSet; } /** *

A unique, case-sensitive identifier that you provide to ensure the * idempotency of the request. For more information, see Ensuring * Idempotency.

*/ inline void SetClientToken(const Aws::String& value) { m_clientTokenHasBeenSet = true; m_clientToken = value; } /** *

A unique, case-sensitive identifier that you provide to ensure the * idempotency of the request. For more information, see Ensuring * Idempotency.

*/ inline void SetClientToken(Aws::String&& value) { m_clientTokenHasBeenSet = true; m_clientToken = std::move(value); } /** *

A unique, case-sensitive identifier that you provide to ensure the * idempotency of the request. For more information, see Ensuring * Idempotency.

*/ inline void SetClientToken(const char* value) { m_clientTokenHasBeenSet = true; m_clientToken.assign(value); } /** *

A unique, case-sensitive identifier that you provide to ensure the * idempotency of the request. For more information, see Ensuring * Idempotency.

*/ inline AllocateIpamPoolCidrRequest& WithClientToken(const Aws::String& value) { SetClientToken(value); return *this;} /** *

A unique, case-sensitive identifier that you provide to ensure the * idempotency of the request. For more information, see Ensuring * Idempotency.

*/ inline AllocateIpamPoolCidrRequest& WithClientToken(Aws::String&& value) { SetClientToken(std::move(value)); return *this;} /** *

A unique, case-sensitive identifier that you provide to ensure the * idempotency of the request. For more information, see Ensuring * Idempotency.

*/ inline AllocateIpamPoolCidrRequest& WithClientToken(const char* value) { SetClientToken(value); return *this;} /** *

A description for the allocation.

*/ inline const Aws::String& GetDescription() const{ return m_description; } /** *

A description for the allocation.

*/ inline bool DescriptionHasBeenSet() const { return m_descriptionHasBeenSet; } /** *

A description for the allocation.

*/ inline void SetDescription(const Aws::String& value) { m_descriptionHasBeenSet = true; m_description = value; } /** *

A description for the allocation.

*/ inline void SetDescription(Aws::String&& value) { m_descriptionHasBeenSet = true; m_description = std::move(value); } /** *

A description for the allocation.

*/ inline void SetDescription(const char* value) { m_descriptionHasBeenSet = true; m_description.assign(value); } /** *

A description for the allocation.

*/ inline AllocateIpamPoolCidrRequest& WithDescription(const Aws::String& value) { SetDescription(value); return *this;} /** *

A description for the allocation.

*/ inline AllocateIpamPoolCidrRequest& WithDescription(Aws::String&& value) { SetDescription(std::move(value)); return *this;} /** *

A description for the allocation.

*/ inline AllocateIpamPoolCidrRequest& WithDescription(const char* value) { SetDescription(value); return *this;} /** *

A preview of the next available CIDR in a pool.

*/ inline bool GetPreviewNextCidr() const{ return m_previewNextCidr; } /** *

A preview of the next available CIDR in a pool.

*/ inline bool PreviewNextCidrHasBeenSet() const { return m_previewNextCidrHasBeenSet; } /** *

A preview of the next available CIDR in a pool.

*/ inline void SetPreviewNextCidr(bool value) { m_previewNextCidrHasBeenSet = true; m_previewNextCidr = value; } /** *

A preview of the next available CIDR in a pool.

*/ inline AllocateIpamPoolCidrRequest& WithPreviewNextCidr(bool value) { SetPreviewNextCidr(value); return *this;} /** *

Exclude a particular CIDR range from being returned by the pool. Disallowed * CIDRs are only allowed if using netmask length for allocation.

*/ inline const Aws::Vector& GetDisallowedCidrs() const{ return m_disallowedCidrs; } /** *

Exclude a particular CIDR range from being returned by the pool. Disallowed * CIDRs are only allowed if using netmask length for allocation.

*/ inline bool DisallowedCidrsHasBeenSet() const { return m_disallowedCidrsHasBeenSet; } /** *

Exclude a particular CIDR range from being returned by the pool. Disallowed * CIDRs are only allowed if using netmask length for allocation.

*/ inline void SetDisallowedCidrs(const Aws::Vector& value) { m_disallowedCidrsHasBeenSet = true; m_disallowedCidrs = value; } /** *

Exclude a particular CIDR range from being returned by the pool. Disallowed * CIDRs are only allowed if using netmask length for allocation.

*/ inline void SetDisallowedCidrs(Aws::Vector&& value) { m_disallowedCidrsHasBeenSet = true; m_disallowedCidrs = std::move(value); } /** *

Exclude a particular CIDR range from being returned by the pool. Disallowed * CIDRs are only allowed if using netmask length for allocation.

*/ inline AllocateIpamPoolCidrRequest& WithDisallowedCidrs(const Aws::Vector& value) { SetDisallowedCidrs(value); return *this;} /** *

Exclude a particular CIDR range from being returned by the pool. Disallowed * CIDRs are only allowed if using netmask length for allocation.

*/ inline AllocateIpamPoolCidrRequest& WithDisallowedCidrs(Aws::Vector&& value) { SetDisallowedCidrs(std::move(value)); return *this;} /** *

Exclude a particular CIDR range from being returned by the pool. Disallowed * CIDRs are only allowed if using netmask length for allocation.

*/ inline AllocateIpamPoolCidrRequest& AddDisallowedCidrs(const Aws::String& value) { m_disallowedCidrsHasBeenSet = true; m_disallowedCidrs.push_back(value); return *this; } /** *

Exclude a particular CIDR range from being returned by the pool. Disallowed * CIDRs are only allowed if using netmask length for allocation.

*/ inline AllocateIpamPoolCidrRequest& AddDisallowedCidrs(Aws::String&& value) { m_disallowedCidrsHasBeenSet = true; m_disallowedCidrs.push_back(std::move(value)); return *this; } /** *

Exclude a particular CIDR range from being returned by the pool. Disallowed * CIDRs are only allowed if using netmask length for allocation.

*/ inline AllocateIpamPoolCidrRequest& AddDisallowedCidrs(const char* value) { m_disallowedCidrsHasBeenSet = true; m_disallowedCidrs.push_back(value); return *this; } private: bool m_dryRun; bool m_dryRunHasBeenSet = false; Aws::String m_ipamPoolId; bool m_ipamPoolIdHasBeenSet = false; Aws::String m_cidr; bool m_cidrHasBeenSet = false; int m_netmaskLength; bool m_netmaskLengthHasBeenSet = false; Aws::String m_clientToken; bool m_clientTokenHasBeenSet = false; Aws::String m_description; bool m_descriptionHasBeenSet = false; bool m_previewNextCidr; bool m_previewNextCidrHasBeenSet = false; Aws::Vector m_disallowedCidrs; bool m_disallowedCidrsHasBeenSet = false; }; } // namespace Model } // namespace EC2 } // namespace Aws