public class InstanceNetworkInterfaceSpecification extends Object implements Serializable, Cloneable
Describes a network interface.
Constructor and Description |
---|
InstanceNetworkInterfaceSpecification() |
Modifier and Type | Method and Description |
---|---|
InstanceNetworkInterfaceSpecification |
clone() |
boolean |
equals(Object obj) |
Boolean |
getAssociatePublicIpAddress()
Indicates whether to assign a public IP address to an instance you launch
in a VPC.
|
Boolean |
getDeleteOnTermination()
If set to
true , the interface is deleted when the instance
is terminated. |
String |
getDescription()
The description of the network interface.
|
Integer |
getDeviceIndex()
The index of the device on the instance for the network interface
attachment.
|
List<String> |
getGroups()
The IDs of the security groups for the network interface.
|
String |
getNetworkInterfaceId()
The ID of the network interface.
|
String |
getPrivateIpAddress()
The private IP address of the network interface.
|
List<PrivateIpAddressSpecification> |
getPrivateIpAddresses()
One or more private IP addresses to assign to the network interface.
|
Integer |
getSecondaryPrivateIpAddressCount()
The number of secondary private IP addresses.
|
String |
getSubnetId()
The ID of the subnet associated with the network string.
|
int |
hashCode() |
Boolean |
isAssociatePublicIpAddress()
Indicates whether to assign a public IP address to an instance you launch
in a VPC.
|
Boolean |
isDeleteOnTermination()
If set to
true , the interface is deleted when the instance
is terminated. |
void |
setAssociatePublicIpAddress(Boolean associatePublicIpAddress)
Indicates whether to assign a public IP address to an instance you launch
in a VPC.
|
void |
setDeleteOnTermination(Boolean deleteOnTermination)
If set to
true , the interface is deleted when the instance
is terminated. |
void |
setDescription(String description)
The description of the network interface.
|
void |
setDeviceIndex(Integer deviceIndex)
The index of the device on the instance for the network interface
attachment.
|
void |
setGroups(Collection<String> groups)
The IDs of the security groups for the network interface.
|
void |
setNetworkInterfaceId(String networkInterfaceId)
The ID of the network interface.
|
void |
setPrivateIpAddress(String privateIpAddress)
The private IP address of the network interface.
|
void |
setPrivateIpAddresses(Collection<PrivateIpAddressSpecification> privateIpAddresses)
One or more private IP addresses to assign to the network interface.
|
void |
setSecondaryPrivateIpAddressCount(Integer secondaryPrivateIpAddressCount)
The number of secondary private IP addresses.
|
void |
setSubnetId(String subnetId)
The ID of the subnet associated with the network string.
|
String |
toString()
Returns a string representation of this object; useful for testing and
debugging.
|
InstanceNetworkInterfaceSpecification |
withAssociatePublicIpAddress(Boolean associatePublicIpAddress)
Indicates whether to assign a public IP address to an instance you launch
in a VPC.
|
InstanceNetworkInterfaceSpecification |
withDeleteOnTermination(Boolean deleteOnTermination)
If set to
true , the interface is deleted when the instance
is terminated. |
InstanceNetworkInterfaceSpecification |
withDescription(String description)
The description of the network interface.
|
InstanceNetworkInterfaceSpecification |
withDeviceIndex(Integer deviceIndex)
The index of the device on the instance for the network interface
attachment.
|
InstanceNetworkInterfaceSpecification |
withGroups(Collection<String> groups)
The IDs of the security groups for the network interface.
|
InstanceNetworkInterfaceSpecification |
withGroups(String... groups)
The IDs of the security groups for the network interface.
|
InstanceNetworkInterfaceSpecification |
withNetworkInterfaceId(String networkInterfaceId)
The ID of the network interface.
|
InstanceNetworkInterfaceSpecification |
withPrivateIpAddress(String privateIpAddress)
The private IP address of the network interface.
|
InstanceNetworkInterfaceSpecification |
withPrivateIpAddresses(Collection<PrivateIpAddressSpecification> privateIpAddresses)
One or more private IP addresses to assign to the network interface.
|
InstanceNetworkInterfaceSpecification |
withPrivateIpAddresses(PrivateIpAddressSpecification... privateIpAddresses)
One or more private IP addresses to assign to the network interface.
|
InstanceNetworkInterfaceSpecification |
withSecondaryPrivateIpAddressCount(Integer secondaryPrivateIpAddressCount)
The number of secondary private IP addresses.
|
InstanceNetworkInterfaceSpecification |
withSubnetId(String subnetId)
The ID of the subnet associated with the network string.
|
public InstanceNetworkInterfaceSpecification()
public void setNetworkInterfaceId(String networkInterfaceId)
The ID of the network interface.
networkInterfaceId
- The ID of the network interface.public String getNetworkInterfaceId()
The ID of the network interface.
public InstanceNetworkInterfaceSpecification withNetworkInterfaceId(String networkInterfaceId)
The ID of the network interface.
networkInterfaceId
- The ID of the network interface.public void setDeviceIndex(Integer deviceIndex)
The index of the device on the instance for the network interface attachment. If you are specifying a network interface in a RunInstances request, you must provide the device index.
deviceIndex
- The index of the device on the instance for the network interface
attachment. If you are specifying a network interface in a
RunInstances request, you must provide the device index.public Integer getDeviceIndex()
The index of the device on the instance for the network interface attachment. If you are specifying a network interface in a RunInstances request, you must provide the device index.
public InstanceNetworkInterfaceSpecification withDeviceIndex(Integer deviceIndex)
The index of the device on the instance for the network interface attachment. If you are specifying a network interface in a RunInstances request, you must provide the device index.
deviceIndex
- The index of the device on the instance for the network interface
attachment. If you are specifying a network interface in a
RunInstances request, you must provide the device index.public void setSubnetId(String subnetId)
The ID of the subnet associated with the network string. Applies only if creating a network interface when launching an instance.
subnetId
- The ID of the subnet associated with the network string. Applies
only if creating a network interface when launching an instance.public String getSubnetId()
The ID of the subnet associated with the network string. Applies only if creating a network interface when launching an instance.
public InstanceNetworkInterfaceSpecification withSubnetId(String subnetId)
The ID of the subnet associated with the network string. Applies only if creating a network interface when launching an instance.
subnetId
- The ID of the subnet associated with the network string. Applies
only if creating a network interface when launching an instance.public void setDescription(String description)
The description of the network interface. Applies only if creating a network interface when launching an instance.
description
- The description of the network interface. Applies only if creating
a network interface when launching an instance.public String getDescription()
The description of the network interface. Applies only if creating a network interface when launching an instance.
public InstanceNetworkInterfaceSpecification withDescription(String description)
The description of the network interface. Applies only if creating a network interface when launching an instance.
description
- The description of the network interface. Applies only if creating
a network interface when launching an instance.public void setPrivateIpAddress(String privateIpAddress)
The private IP address of the network interface. Applies only if creating a network interface when launching an instance.
privateIpAddress
- The private IP address of the network interface. Applies only if
creating a network interface when launching an instance.public String getPrivateIpAddress()
The private IP address of the network interface. Applies only if creating a network interface when launching an instance.
public InstanceNetworkInterfaceSpecification withPrivateIpAddress(String privateIpAddress)
The private IP address of the network interface. Applies only if creating a network interface when launching an instance.
privateIpAddress
- The private IP address of the network interface. Applies only if
creating a network interface when launching an instance.public List<String> getGroups()
The IDs of the security groups for the network interface. Applies only if creating a network interface when launching an instance.
public void setGroups(Collection<String> groups)
The IDs of the security groups for the network interface. Applies only if creating a network interface when launching an instance.
groups
- The IDs of the security groups for the network interface. Applies
only if creating a network interface when launching an instance.public InstanceNetworkInterfaceSpecification withGroups(String... groups)
The IDs of the security groups for the network interface. Applies only if creating a network interface when launching an instance.
NOTE: This method appends the values to the existing list (if
any). Use setGroups(java.util.Collection)
or
withGroups(java.util.Collection)
if you want to override the
existing values.
groups
- The IDs of the security groups for the network interface. Applies
only if creating a network interface when launching an instance.public InstanceNetworkInterfaceSpecification withGroups(Collection<String> groups)
The IDs of the security groups for the network interface. Applies only if creating a network interface when launching an instance.
groups
- The IDs of the security groups for the network interface. Applies
only if creating a network interface when launching an instance.public void setDeleteOnTermination(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.
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.public Boolean getDeleteOnTermination()
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.
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.public InstanceNetworkInterfaceSpecification withDeleteOnTermination(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.
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.public Boolean isDeleteOnTermination()
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.
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.public List<PrivateIpAddressSpecification> getPrivateIpAddresses()
One or more private IP addresses to assign to the network interface. Only one private IP address can be designated as primary.
public void setPrivateIpAddresses(Collection<PrivateIpAddressSpecification> privateIpAddresses)
One or more private IP addresses to assign to the network interface. Only one private IP address can be designated as primary.
privateIpAddresses
- One or more private IP addresses to assign to the network
interface. Only one private IP address can be designated as
primary.public InstanceNetworkInterfaceSpecification withPrivateIpAddresses(PrivateIpAddressSpecification... privateIpAddresses)
One or more private IP addresses to assign to the network interface. Only one private IP address can be designated as primary.
NOTE: This method appends the values to the existing list (if
any). Use setPrivateIpAddresses(java.util.Collection)
or
withPrivateIpAddresses(java.util.Collection)
if you want to
override the existing values.
privateIpAddresses
- One or more private IP addresses to assign to the network
interface. Only one private IP address can be designated as
primary.public InstanceNetworkInterfaceSpecification withPrivateIpAddresses(Collection<PrivateIpAddressSpecification> privateIpAddresses)
One or more private IP addresses to assign to the network interface. Only one private IP address can be designated as primary.
privateIpAddresses
- One or more private IP addresses to assign to the network
interface. Only one private IP address can be designated as
primary.public void setSecondaryPrivateIpAddressCount(Integer secondaryPrivateIpAddressCount)
The number of secondary private IP addresses. You can't specify this option and specify more than one private IP address using the private IP addresses option.
secondaryPrivateIpAddressCount
- The number of secondary private IP addresses. You can't specify
this option and specify more than one private IP address using the
private IP addresses option.public Integer getSecondaryPrivateIpAddressCount()
The number of secondary private IP addresses. You can't specify this option and specify more than one private IP address using the private IP addresses option.
public InstanceNetworkInterfaceSpecification withSecondaryPrivateIpAddressCount(Integer secondaryPrivateIpAddressCount)
The number of secondary private IP addresses. You can't specify this option and specify more than one private IP address using the private IP addresses option.
secondaryPrivateIpAddressCount
- The number of secondary private IP addresses. You can't specify
this option and specify more than one private IP address using the
private IP addresses option.public void setAssociatePublicIpAddress(Boolean associatePublicIpAddress)
Indicates whether to assign a public IP 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
.
associatePublicIpAddress
- Indicates whether to assign a public IP 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
.public Boolean getAssociatePublicIpAddress()
Indicates whether to assign a public IP 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
.
true
.public InstanceNetworkInterfaceSpecification withAssociatePublicIpAddress(Boolean associatePublicIpAddress)
Indicates whether to assign a public IP 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
.
associatePublicIpAddress
- Indicates whether to assign a public IP 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
.public Boolean isAssociatePublicIpAddress()
Indicates whether to assign a public IP 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
.
true
.public String toString()
toString
in class Object
Object.toString()
public InstanceNetworkInterfaceSpecification clone()
Copyright © 2013 Amazon Web Services, Inc. All Rights Reserved.