AWS SDK for Go (PILOT)
API Reference

PREVIEW DOCUMENTATION - This is a preview of a new format for the AWS SDK for Go API Reference documentation. For the current AWS SDK for Go API Reference, see https://docs.aws.amazon.com/sdk-for-go/api/.

We welcome your feedback on this new version of the documentation. Send your comments to aws-sdkdocs-feedback@amazon.com.

NatGateway

import "github.com/aws/aws-sdk-go/service/ec2"

type NatGateway struct { CreateTime *time.Time `locationName:"createTime" type:"timestamp"` DeleteTime *time.Time `locationName:"deleteTime" type:"timestamp"` FailureCode *string `locationName:"failureCode" type:"string"` FailureMessage *string `locationName:"failureMessage" type:"string"` NatGatewayAddresses []*NatGatewayAddress `locationName:"natGatewayAddressSet" locationNameList:"item" type:"list"` NatGatewayId *string `locationName:"natGatewayId" type:"string"` ProvisionedBandwidth *ProvisionedBandwidth `locationName:"provisionedBandwidth" type:"structure"` State *string `locationName:"state" type:"string" enum:"NatGatewayState"` SubnetId *string `locationName:"subnetId" type:"string"` Tags []*Tag `locationName:"tagSet" locationNameList:"item" type:"list"` VpcId *string `locationName:"vpcId" type:"string"` }

Describes a NAT gateway.

CreateTime

Type: *time.Time

The date and time the NAT gateway was created.

DeleteTime

Type: *time.Time

The date and time the NAT gateway was deleted, if applicable.

FailureCode

Type: *string

If the NAT gateway could not be created, specifies the error code for the failure. (InsufficientFreeAddressesInSubnet | Gateway.NotAttached | InvalidAllocationID.NotFound | Resource.AlreadyAssociated | InternalError | InvalidSubnetID.NotFound)

FailureMessage

Type: *string

If the NAT gateway could not be created, specifies the error message for the failure, that corresponds to the error code.

  • For InsufficientFreeAddressesInSubnet: "Subnet has insufficient free addresses to create this NAT gateway"

  • For Gateway.NotAttached: "Network vpc-xxxxxxxx has no Internet gateway attached"

  • For InvalidAllocationID.NotFound: "Elastic IP address eipalloc-xxxxxxxx could not be associated with this NAT gateway"

  • For Resource.AlreadyAssociated: "Elastic IP address eipalloc-xxxxxxxx is already associated"

  • For InternalError: "Network interface eni-xxxxxxxx, created and used internally by this NAT gateway is in an invalid state. Please try again."

  • For InvalidSubnetID.NotFound: "The specified subnet subnet-xxxxxxxx does not exist or could not be found."

NatGatewayAddresses

Describes the IP addresses and network interface associated with a NAT gateway.

NatGatewayId

Type: *string

The ID of the NAT gateway.

ProvisionedBandwidth

Reserved. If you need to sustain traffic greater than the documented limits (https://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/vpc-nat-gateway.html), contact us through the Support Center (https://console.aws.amazon.com/support/home?).

State

Type: *string

The state of the NAT gateway.

  • pending: The NAT gateway is being created and is not ready to process traffic.

  • failed: The NAT gateway could not be created. Check the failureCode and failureMessage fields for the reason.

  • available: The NAT gateway is able to process traffic. This status remains until you delete the NAT gateway, and does not indicate the health of the NAT gateway.

  • deleting: The NAT gateway is in the process of being terminated and may still be processing traffic.

  • deleted: The NAT gateway has been terminated and is no longer processing traffic.

SubnetId

Type: *string

The ID of the subnet in which the NAT gateway is located.

Tags

Describes a tag.

VpcId

Type: *string

The ID of the VPC in which the NAT gateway is located.

Method

GoString

func (s NatGateway) GoString() string

GoString returns the string representation

SetCreateTime

func (s *NatGateway) SetCreateTime(v time.Time) *NatGateway

SetCreateTime sets the CreateTime field's value.

SetDeleteTime

func (s *NatGateway) SetDeleteTime(v time.Time) *NatGateway

SetDeleteTime sets the DeleteTime field's value.

SetFailureCode

func (s *NatGateway) SetFailureCode(v string) *NatGateway

SetFailureCode sets the FailureCode field's value.

SetFailureMessage

func (s *NatGateway) SetFailureMessage(v string) *NatGateway

SetFailureMessage sets the FailureMessage field's value.

SetNatGatewayAddresses

func (s *NatGateway) SetNatGatewayAddresses(v []*NatGatewayAddress) *NatGateway

SetNatGatewayAddresses sets the NatGatewayAddresses field's value.

SetNatGatewayId

func (s *NatGateway) SetNatGatewayId(v string) *NatGateway

SetNatGatewayId sets the NatGatewayId field's value.

SetProvisionedBandwidth

func (s *NatGateway) SetProvisionedBandwidth(v *ProvisionedBandwidth) *NatGateway

SetProvisionedBandwidth sets the ProvisionedBandwidth field's value.

SetState

func (s *NatGateway) SetState(v string) *NatGateway

SetState sets the State field's value.

SetSubnetId

func (s *NatGateway) SetSubnetId(v string) *NatGateway

SetSubnetId sets the SubnetId field's value.

SetTags

func (s *NatGateway) SetTags(v []*Tag) *NatGateway

SetTags sets the Tags field's value.

SetVpcId

func (s *NatGateway) SetVpcId(v string) *NatGateway

SetVpcId sets the VpcId field's value.

String

func (s NatGateway) String() string

String returns the string representation

On this page: