Interface InstanceNetworkInterfaceSpecification.Builder

    • Method Detail

      • associatePublicIpAddress

        InstanceNetworkInterfaceSpecification.Builder associatePublicIpAddress​(Boolean associatePublicIpAddress)

        Indicates whether to assign a public IPv4 address to an instance you launch in a VPC. The public IP address can only be assigned to a network interface for eth0, and can only be assigned to a new network interface, not an existing one. You cannot specify more than one network interface in the request. If launching into a default subnet, the default value is true.

        Parameters:
        associatePublicIpAddress - Indicates whether to assign a public IPv4 address to an instance you launch in a VPC. The public IP address can only be assigned to a network interface for eth0, and can only be assigned to a new network interface, not an existing one. You cannot specify more than one network interface in the request. If launching into a default subnet, the default value is true.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • deleteOnTermination

        InstanceNetworkInterfaceSpecification.Builder deleteOnTermination​(Boolean deleteOnTermination)

        If set to true, the interface is deleted when the instance is terminated. You can specify true only if creating a new network interface when launching an instance.

        Parameters:
        deleteOnTermination - If set to true, the interface is deleted when the instance is terminated. You can specify true only if creating a new network interface when launching an instance.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • description

        InstanceNetworkInterfaceSpecification.Builder description​(String description)

        The description of the network interface. Applies only if creating a network interface when launching an instance.

        Parameters:
        description - The description of the network interface. Applies only if creating a network interface when launching an instance.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • deviceIndex

        InstanceNetworkInterfaceSpecification.Builder deviceIndex​(Integer deviceIndex)

        The position of the network interface in the attachment order. A primary network interface has a device index of 0.

        If you specify a network interface when launching an instance, you must specify the device index.

        Parameters:
        deviceIndex - The position of the network interface in the attachment order. A primary network interface has a device index of 0.

        If you specify a network interface when launching an instance, you must specify the device index.

        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • groups

        InstanceNetworkInterfaceSpecification.Builder groups​(Collection<String> groups)

        The IDs of the security groups for the network interface. Applies only if creating a network interface when launching an instance.

        Parameters:
        groups - The IDs of the security groups for the network interface. Applies only if creating a network interface when launching an instance.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • groups

        InstanceNetworkInterfaceSpecification.Builder groups​(String... groups)

        The IDs of the security groups for the network interface. Applies only if creating a network interface when launching an instance.

        Parameters:
        groups - The IDs of the security groups for the network interface. Applies only if creating a network interface when launching an instance.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • ipv6AddressCount

        InstanceNetworkInterfaceSpecification.Builder ipv6AddressCount​(Integer ipv6AddressCount)

        A number of IPv6 addresses to assign to the network interface. Amazon EC2 chooses the IPv6 addresses from the range of the subnet. You cannot specify this option and the option to assign specific IPv6 addresses in the same request. You can specify this option if you've specified a minimum number of instances to launch.

        Parameters:
        ipv6AddressCount - A number of IPv6 addresses to assign to the network interface. Amazon EC2 chooses the IPv6 addresses from the range of the subnet. You cannot specify this option and the option to assign specific IPv6 addresses in the same request. You can specify this option if you've specified a minimum number of instances to launch.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • ipv6Addresses

        InstanceNetworkInterfaceSpecification.Builder ipv6Addresses​(Collection<InstanceIpv6Address> ipv6Addresses)

        The IPv6 addresses to assign to the network interface. You cannot specify this option and the option to assign a number of IPv6 addresses in the same request. You cannot specify this option if you've specified a minimum number of instances to launch.

        Parameters:
        ipv6Addresses - The IPv6 addresses to assign to the network interface. You cannot specify this option and the option to assign a number of IPv6 addresses in the same request. You cannot specify this option if you've specified a minimum number of instances to launch.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • ipv6Addresses

        InstanceNetworkInterfaceSpecification.Builder ipv6Addresses​(InstanceIpv6Address... ipv6Addresses)

        The IPv6 addresses to assign to the network interface. You cannot specify this option and the option to assign a number of IPv6 addresses in the same request. You cannot specify this option if you've specified a minimum number of instances to launch.

        Parameters:
        ipv6Addresses - The IPv6 addresses to assign to the network interface. You cannot specify this option and the option to assign a number of IPv6 addresses in the same request. You cannot specify this option if you've specified a minimum number of instances to launch.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • networkInterfaceId

        InstanceNetworkInterfaceSpecification.Builder networkInterfaceId​(String networkInterfaceId)

        The ID of the network interface.

        If you are creating a Spot Fleet, omit this parameter because you can’t specify a network interface ID in a launch specification.

        Parameters:
        networkInterfaceId - The ID of the network interface.

        If you are creating a Spot Fleet, omit this parameter because you can’t specify a network interface ID in a launch specification.

        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • privateIpAddress

        InstanceNetworkInterfaceSpecification.Builder privateIpAddress​(String privateIpAddress)

        The private IPv4 address of the network interface. Applies only if creating a network interface when launching an instance. You cannot specify this option if you're launching more than one instance in a RunInstances request.

        Parameters:
        privateIpAddress - The private IPv4 address of the network interface. Applies only if creating a network interface when launching an instance. You cannot specify this option if you're launching more than one instance in a RunInstances request.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • privateIpAddresses

        InstanceNetworkInterfaceSpecification.Builder privateIpAddresses​(Collection<PrivateIpAddressSpecification> privateIpAddresses)

        The private IPv4 addresses to assign to the network interface. Only one private IPv4 address can be designated as primary. You cannot specify this option if you're launching more than one instance in a RunInstances request.

        Parameters:
        privateIpAddresses - The private IPv4 addresses to assign to the network interface. Only one private IPv4 address can be designated as primary. You cannot specify this option if you're launching more than one instance in a RunInstances request.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • privateIpAddresses

        InstanceNetworkInterfaceSpecification.Builder privateIpAddresses​(PrivateIpAddressSpecification... privateIpAddresses)

        The private IPv4 addresses to assign to the network interface. Only one private IPv4 address can be designated as primary. You cannot specify this option if you're launching more than one instance in a RunInstances request.

        Parameters:
        privateIpAddresses - The private IPv4 addresses to assign to the network interface. Only one private IPv4 address can be designated as primary. You cannot specify this option if you're launching more than one instance in a RunInstances request.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • secondaryPrivateIpAddressCount

        InstanceNetworkInterfaceSpecification.Builder secondaryPrivateIpAddressCount​(Integer secondaryPrivateIpAddressCount)

        The number of secondary private IPv4 addresses. You can't specify this option and specify more than one private IP address using the private IP addresses option. You cannot specify this option if you're launching more than one instance in a RunInstances request.

        Parameters:
        secondaryPrivateIpAddressCount - The number of secondary private IPv4 addresses. You can't specify this option and specify more than one private IP address using the private IP addresses option. You cannot specify this option if you're launching more than one instance in a RunInstances request.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • subnetId

        InstanceNetworkInterfaceSpecification.Builder subnetId​(String subnetId)

        The ID of the subnet associated with the network interface. Applies only if creating a network interface when launching an instance.

        Parameters:
        subnetId - The ID of the subnet associated with the network interface. Applies only if creating a network interface when launching an instance.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • associateCarrierIpAddress

        InstanceNetworkInterfaceSpecification.Builder associateCarrierIpAddress​(Boolean associateCarrierIpAddress)

        Indicates whether to assign a carrier IP address to the network interface.

        You can only assign a carrier IP address to a network interface that is in a subnet in a Wavelength Zone. For more information about carrier IP addresses, see Carrier IP address in the Amazon Web Services Wavelength Developer Guide.

        Parameters:
        associateCarrierIpAddress - Indicates whether to assign a carrier IP address to the network interface.

        You can only assign a carrier IP address to a network interface that is in a subnet in a Wavelength Zone. For more information about carrier IP addresses, see Carrier IP address in the Amazon Web Services Wavelength Developer Guide.

        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • interfaceType

        InstanceNetworkInterfaceSpecification.Builder interfaceType​(String interfaceType)

        The type of network interface.

        Valid values: interface | efa

        Parameters:
        interfaceType - The type of network interface.

        Valid values: interface | efa

        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • networkCardIndex

        InstanceNetworkInterfaceSpecification.Builder networkCardIndex​(Integer networkCardIndex)

        The index of the network card. Some instance types support multiple network cards. The primary network interface must be assigned to network card index 0. The default is network card index 0.

        If you are using RequestSpotInstances to create Spot Instances, omit this parameter because you can’t specify the network card index when using this API. To specify the network card index, use RunInstances.

        Parameters:
        networkCardIndex - The index of the network card. Some instance types support multiple network cards. The primary network interface must be assigned to network card index 0. The default is network card index 0.

        If you are using RequestSpotInstances to create Spot Instances, omit this parameter because you can’t specify the network card index when using this API. To specify the network card index, use RunInstances.

        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • ipv4Prefixes

        InstanceNetworkInterfaceSpecification.Builder ipv4Prefixes​(Collection<Ipv4PrefixSpecificationRequest> ipv4Prefixes)

        The IPv4 delegated prefixes to be assigned to the network interface. You cannot use this option if you use the Ipv4PrefixCount option.

        Parameters:
        ipv4Prefixes - The IPv4 delegated prefixes to be assigned to the network interface. You cannot use this option if you use the Ipv4PrefixCount option.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • ipv4Prefixes

        InstanceNetworkInterfaceSpecification.Builder ipv4Prefixes​(Ipv4PrefixSpecificationRequest... ipv4Prefixes)

        The IPv4 delegated prefixes to be assigned to the network interface. You cannot use this option if you use the Ipv4PrefixCount option.

        Parameters:
        ipv4Prefixes - The IPv4 delegated prefixes to be assigned to the network interface. You cannot use this option if you use the Ipv4PrefixCount option.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • ipv4PrefixCount

        InstanceNetworkInterfaceSpecification.Builder ipv4PrefixCount​(Integer ipv4PrefixCount)

        The number of IPv4 delegated prefixes to be automatically assigned to the network interface. You cannot use this option if you use the Ipv4Prefix option.

        Parameters:
        ipv4PrefixCount - The number of IPv4 delegated prefixes to be automatically assigned to the network interface. You cannot use this option if you use the Ipv4Prefix option.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • ipv6Prefixes

        InstanceNetworkInterfaceSpecification.Builder ipv6Prefixes​(Collection<Ipv6PrefixSpecificationRequest> ipv6Prefixes)

        The IPv6 delegated prefixes to be assigned to the network interface. You cannot use this option if you use the Ipv6PrefixCount option.

        Parameters:
        ipv6Prefixes - The IPv6 delegated prefixes to be assigned to the network interface. You cannot use this option if you use the Ipv6PrefixCount option.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • ipv6Prefixes

        InstanceNetworkInterfaceSpecification.Builder ipv6Prefixes​(Ipv6PrefixSpecificationRequest... ipv6Prefixes)

        The IPv6 delegated prefixes to be assigned to the network interface. You cannot use this option if you use the Ipv6PrefixCount option.

        Parameters:
        ipv6Prefixes - The IPv6 delegated prefixes to be assigned to the network interface. You cannot use this option if you use the Ipv6PrefixCount option.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • ipv6PrefixCount

        InstanceNetworkInterfaceSpecification.Builder ipv6PrefixCount​(Integer ipv6PrefixCount)

        The number of IPv6 delegated prefixes to be automatically assigned to the network interface. You cannot use this option if you use the Ipv6Prefix option.

        Parameters:
        ipv6PrefixCount - The number of IPv6 delegated prefixes to be automatically assigned to the network interface. You cannot use this option if you use the Ipv6Prefix option.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • primaryIpv6

        InstanceNetworkInterfaceSpecification.Builder primaryIpv6​(Boolean primaryIpv6)

        The primary IPv6 address of the network interface. When you enable an IPv6 GUA address to be a primary IPv6, the first IPv6 GUA will be made the primary IPv6 address until the instance is terminated or the network interface is detached. For more information about primary IPv6 addresses, see RunInstances.

        Parameters:
        primaryIpv6 - The primary IPv6 address of the network interface. When you enable an IPv6 GUA address to be a primary IPv6, the first IPv6 GUA will be made the primary IPv6 address until the instance is terminated or the network interface is detached. For more information about primary IPv6 addresses, see RunInstances.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • enaSrdSpecification

        InstanceNetworkInterfaceSpecification.Builder enaSrdSpecification​(EnaSrdSpecificationRequest enaSrdSpecification)

        Specifies the ENA Express settings for the network interface that's attached to the instance.

        Parameters:
        enaSrdSpecification - Specifies the ENA Express settings for the network interface that's attached to the instance.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • connectionTrackingSpecification

        InstanceNetworkInterfaceSpecification.Builder connectionTrackingSpecification​(ConnectionTrackingSpecificationRequest connectionTrackingSpecification)

        A security group connection tracking specification that enables you to set the timeout for connection tracking on an Elastic network interface. For more information, see Connection tracking timeouts in the Amazon Elastic Compute Cloud User Guide.

        Parameters:
        connectionTrackingSpecification - A security group connection tracking specification that enables you to set the timeout for connection tracking on an Elastic network interface. For more information, see Connection tracking timeouts in the Amazon Elastic Compute Cloud User Guide.
        Returns:
        Returns a reference to this object so that method calls can be chained together.