@Generated(value="software.amazon.awssdk:codegen") public final class Instance extends Object implements SdkPojo, Serializable, ToCopyableBuilder<Instance.Builder,Instance>
Describes an instance.
| Modifier and Type | Class and Description |
|---|---|
static interface |
Instance.Builder |
| Modifier and Type | Method and Description |
|---|---|
Integer |
amiLaunchIndex()
The AMI launch index, which can be used to find this instance in the launch group.
|
ArchitectureValues |
architecture()
The architecture of the image.
|
String |
architectureAsString()
The architecture of the image.
|
List<InstanceBlockDeviceMapping> |
blockDeviceMappings()
Any block device mapping entries for the instance.
|
BootModeValues |
bootMode()
The boot mode of the instance.
|
String |
bootModeAsString()
The boot mode of the instance.
|
static Instance.Builder |
builder() |
String |
capacityReservationId()
The ID of the Capacity Reservation.
|
CapacityReservationSpecificationResponse |
capacityReservationSpecification()
Information about the Capacity Reservation targeting option.
|
String |
clientToken()
The idempotency token you provided when you launched the instance, if applicable.
|
CpuOptions |
cpuOptions()
The CPU options for the instance.
|
Boolean |
ebsOptimized()
Indicates whether the instance is optimized for Amazon EBS I/O.
|
List<ElasticGpuAssociation> |
elasticGpuAssociations()
The Elastic GPU associated with the instance.
|
List<ElasticInferenceAcceleratorAssociation> |
elasticInferenceAcceleratorAssociations()
The elastic inference accelerator associated with the instance.
|
Boolean |
enaSupport()
Specifies whether enhanced networking with ENA is enabled.
|
EnclaveOptions |
enclaveOptions()
Indicates whether the instance is enabled for AWS Nitro Enclaves.
|
boolean |
equals(Object obj) |
boolean |
equalsBySdkFields(Object obj) |
<T> Optional<T> |
getValueForField(String fieldName,
Class<T> clazz) |
boolean |
hasBlockDeviceMappings()
Returns true if the BlockDeviceMappings property was specified by the sender (it may be empty), or false if the
sender did not specify the value (it will be empty).
|
boolean |
hasElasticGpuAssociations()
Returns true if the ElasticGpuAssociations property was specified by the sender (it may be empty), or false if
the sender did not specify the value (it will be empty).
|
boolean |
hasElasticInferenceAcceleratorAssociations()
Returns true if the ElasticInferenceAcceleratorAssociations property was specified by the sender (it may be
empty), or false if the sender did not specify the value (it will be empty).
|
int |
hashCode() |
boolean |
hasLicenses()
Returns true if the Licenses property was specified by the sender (it may be empty), or false if the sender did
not specify the value (it will be empty).
|
boolean |
hasNetworkInterfaces()
Returns true if the NetworkInterfaces property was specified by the sender (it may be empty), or false if the
sender did not specify the value (it will be empty).
|
boolean |
hasProductCodes()
Returns true if the ProductCodes property was specified by the sender (it may be empty), or false if the sender
did not specify the value (it will be empty).
|
boolean |
hasSecurityGroups()
Returns true if the SecurityGroups property was specified by the sender (it may be empty), or false if the sender
did not specify the value (it will be empty).
|
boolean |
hasTags()
Returns true if the Tags property was specified by the sender (it may be empty), or false if the sender did not
specify the value (it will be empty).
|
HibernationOptions |
hibernationOptions()
Indicates whether the instance is enabled for hibernation.
|
HypervisorType |
hypervisor()
The hypervisor type of the instance.
|
String |
hypervisorAsString()
The hypervisor type of the instance.
|
IamInstanceProfile |
iamInstanceProfile()
The IAM instance profile associated with the instance, if applicable.
|
String |
imageId()
The ID of the AMI used to launch the instance.
|
String |
instanceId()
The ID of the instance.
|
InstanceLifecycleType |
instanceLifecycle()
Indicates whether this is a Spot Instance or a Scheduled Instance.
|
String |
instanceLifecycleAsString()
Indicates whether this is a Spot Instance or a Scheduled Instance.
|
InstanceType |
instanceType()
The instance type.
|
String |
instanceTypeAsString()
The instance type.
|
String |
kernelId()
The kernel associated with this instance, if applicable.
|
String |
keyName()
The name of the key pair, if this instance was launched with an associated key pair.
|
Instant |
launchTime()
The time the instance was launched.
|
List<LicenseConfiguration> |
licenses()
The license configurations.
|
InstanceMetadataOptionsResponse |
metadataOptions()
The metadata options for the instance.
|
Monitoring |
monitoring()
The monitoring for the instance.
|
List<InstanceNetworkInterface> |
networkInterfaces()
[EC2-VPC] The network interfaces for the instance.
|
String |
outpostArn()
The Amazon Resource Name (ARN) of the Outpost.
|
Placement |
placement()
The location where the instance launched, if applicable.
|
PlatformValues |
platform()
The value is
Windows for Windows instances; otherwise blank. |
String |
platformAsString()
The value is
Windows for Windows instances; otherwise blank. |
String |
privateDnsName()
(IPv4 only) The private DNS hostname name assigned to the instance.
|
String |
privateIpAddress()
The private IPv4 address assigned to the instance.
|
List<ProductCode> |
productCodes()
The product codes attached to this instance, if applicable.
|
String |
publicDnsName()
(IPv4 only) The public DNS name assigned to the instance.
|
String |
publicIpAddress()
The public IPv4 address, or the Carrier IP address assigned to the instance, if applicable.
|
String |
ramdiskId()
The RAM disk associated with this instance, if applicable.
|
String |
rootDeviceName()
The device name of the root device volume (for example,
/dev/sda1). |
DeviceType |
rootDeviceType()
The root device type used by the AMI.
|
String |
rootDeviceTypeAsString()
The root device type used by the AMI.
|
List<SdkField<?>> |
sdkFields() |
List<GroupIdentifier> |
securityGroups()
The security groups for the instance.
|
static Class<? extends Instance.Builder> |
serializableBuilderClass() |
Boolean |
sourceDestCheck()
Indicates whether source/destination checking is enabled.
|
String |
spotInstanceRequestId()
If the request is a Spot Instance request, the ID of the request.
|
String |
sriovNetSupport()
Specifies whether enhanced networking with the Intel 82599 Virtual Function interface is enabled.
|
InstanceState |
state()
The current state of the instance.
|
StateReason |
stateReason()
The reason for the most recent state transition.
|
String |
stateTransitionReason()
The reason for the most recent state transition.
|
String |
subnetId()
[EC2-VPC] The ID of the subnet in which the instance is running.
|
List<Tag> |
tags()
Any tags assigned to the instance.
|
Instance.Builder |
toBuilder() |
String |
toString()
Returns a string representation of this object.
|
VirtualizationType |
virtualizationType()
The virtualization type of the instance.
|
String |
virtualizationTypeAsString()
The virtualization type of the instance.
|
String |
vpcId()
[EC2-VPC] The ID of the VPC in which the instance is running.
|
clone, finalize, getClass, notify, notifyAll, wait, wait, waitcopypublic final Integer amiLaunchIndex()
The AMI launch index, which can be used to find this instance in the launch group.
public final String imageId()
The ID of the AMI used to launch the instance.
public final String instanceId()
The ID of the instance.
public final InstanceType instanceType()
The instance type.
If the service returns an enum value that is not available in the current SDK version, instanceType will
return InstanceType.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available from
instanceTypeAsString().
InstanceTypepublic final String instanceTypeAsString()
The instance type.
If the service returns an enum value that is not available in the current SDK version, instanceType will
return InstanceType.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available from
instanceTypeAsString().
InstanceTypepublic final String kernelId()
The kernel associated with this instance, if applicable.
public final String keyName()
The name of the key pair, if this instance was launched with an associated key pair.
public final Instant launchTime()
The time the instance was launched.
public final Monitoring monitoring()
The monitoring for the instance.
public final Placement placement()
The location where the instance launched, if applicable.
public final PlatformValues platform()
The value is Windows for Windows instances; otherwise blank.
If the service returns an enum value that is not available in the current SDK version, platform will
return PlatformValues.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available from
platformAsString().
Windows for Windows instances; otherwise blank.PlatformValuespublic final String platformAsString()
The value is Windows for Windows instances; otherwise blank.
If the service returns an enum value that is not available in the current SDK version, platform will
return PlatformValues.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available from
platformAsString().
Windows for Windows instances; otherwise blank.PlatformValuespublic final String privateDnsName()
(IPv4 only) The private DNS hostname name assigned to the instance. This DNS hostname can only be used inside the
Amazon EC2 network. This name is not available until the instance enters the running state.
[EC2-VPC] The Amazon-provided DNS server resolves Amazon-provided private DNS hostnames if you've enabled DNS resolution and DNS hostnames in your VPC. If you are not using the Amazon-provided DNS server in your VPC, your custom domain name servers must resolve the hostname as appropriate.
running state.
[EC2-VPC] The Amazon-provided DNS server resolves Amazon-provided private DNS hostnames if you've enabled DNS resolution and DNS hostnames in your VPC. If you are not using the Amazon-provided DNS server in your VPC, your custom domain name servers must resolve the hostname as appropriate.
public final String privateIpAddress()
The private IPv4 address assigned to the instance.
public final boolean hasProductCodes()
public final List<ProductCode> productCodes()
The product codes attached to this instance, if applicable.
Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.
You can use hasProductCodes() to see if a value was sent in this field.
public final String publicDnsName()
(IPv4 only) The public DNS name assigned to the instance. This name is not available until the instance enters
the running state. For EC2-VPC, this name is only available if you've enabled DNS hostnames for your
VPC.
running state. For EC2-VPC, this name is only available if you've enabled DNS
hostnames for your VPC.public final String publicIpAddress()
The public IPv4 address, or the Carrier IP address assigned to the instance, if applicable.
A Carrier IP address only applies to an instance launched in a subnet associated with a Wavelength Zone.
A Carrier IP address only applies to an instance launched in a subnet associated with a Wavelength Zone.
public final String ramdiskId()
The RAM disk associated with this instance, if applicable.
public final InstanceState state()
The current state of the instance.
public final String stateTransitionReason()
The reason for the most recent state transition. This might be an empty string.
public final String subnetId()
[EC2-VPC] The ID of the subnet in which the instance is running.
public final String vpcId()
[EC2-VPC] The ID of the VPC in which the instance is running.
public final ArchitectureValues architecture()
The architecture of the image.
If the service returns an enum value that is not available in the current SDK version, architecture will
return ArchitectureValues.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available from
architectureAsString().
ArchitectureValuespublic final String architectureAsString()
The architecture of the image.
If the service returns an enum value that is not available in the current SDK version, architecture will
return ArchitectureValues.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available from
architectureAsString().
ArchitectureValuespublic final boolean hasBlockDeviceMappings()
public final List<InstanceBlockDeviceMapping> blockDeviceMappings()
Any block device mapping entries for the instance.
Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.
You can use hasBlockDeviceMappings() to see if a value was sent in this field.
public final String clientToken()
The idempotency token you provided when you launched the instance, if applicable.
public final Boolean ebsOptimized()
Indicates whether the instance is optimized for Amazon EBS I/O. This optimization provides dedicated throughput to Amazon EBS and an optimized configuration stack to provide optimal I/O performance. This optimization isn't available with all instance types. Additional usage charges apply when using an EBS Optimized instance.
public final Boolean enaSupport()
Specifies whether enhanced networking with ENA is enabled.
public final HypervisorType hypervisor()
The hypervisor type of the instance. The value xen is used for both Xen and Nitro hypervisors.
If the service returns an enum value that is not available in the current SDK version, hypervisor will
return HypervisorType.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available from
hypervisorAsString().
xen is used for both Xen and Nitro
hypervisors.HypervisorTypepublic final String hypervisorAsString()
The hypervisor type of the instance. The value xen is used for both Xen and Nitro hypervisors.
If the service returns an enum value that is not available in the current SDK version, hypervisor will
return HypervisorType.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available from
hypervisorAsString().
xen is used for both Xen and Nitro
hypervisors.HypervisorTypepublic final IamInstanceProfile iamInstanceProfile()
The IAM instance profile associated with the instance, if applicable.
public final InstanceLifecycleType instanceLifecycle()
Indicates whether this is a Spot Instance or a Scheduled Instance.
If the service returns an enum value that is not available in the current SDK version, instanceLifecycle
will return InstanceLifecycleType.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is
available from instanceLifecycleAsString().
InstanceLifecycleTypepublic final String instanceLifecycleAsString()
Indicates whether this is a Spot Instance or a Scheduled Instance.
If the service returns an enum value that is not available in the current SDK version, instanceLifecycle
will return InstanceLifecycleType.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is
available from instanceLifecycleAsString().
InstanceLifecycleTypepublic final boolean hasElasticGpuAssociations()
public final List<ElasticGpuAssociation> elasticGpuAssociations()
The Elastic GPU associated with the instance.
Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.
You can use hasElasticGpuAssociations() to see if a value was sent in this field.
public final boolean hasElasticInferenceAcceleratorAssociations()
public final List<ElasticInferenceAcceleratorAssociation> elasticInferenceAcceleratorAssociations()
The elastic inference accelerator associated with the instance.
Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.
You can use hasElasticInferenceAcceleratorAssociations() to see if a value was sent in this field.
public final boolean hasNetworkInterfaces()
public final List<InstanceNetworkInterface> networkInterfaces()
[EC2-VPC] The network interfaces for the instance.
Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.
You can use hasNetworkInterfaces() to see if a value was sent in this field.
public final String outpostArn()
The Amazon Resource Name (ARN) of the Outpost.
public final String rootDeviceName()
The device name of the root device volume (for example, /dev/sda1).
/dev/sda1).public final DeviceType rootDeviceType()
The root device type used by the AMI. The AMI can use an EBS volume or an instance store volume.
If the service returns an enum value that is not available in the current SDK version, rootDeviceType
will return DeviceType.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available from
rootDeviceTypeAsString().
DeviceTypepublic final String rootDeviceTypeAsString()
The root device type used by the AMI. The AMI can use an EBS volume or an instance store volume.
If the service returns an enum value that is not available in the current SDK version, rootDeviceType
will return DeviceType.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available from
rootDeviceTypeAsString().
DeviceTypepublic final boolean hasSecurityGroups()
public final List<GroupIdentifier> securityGroups()
The security groups for the instance.
Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.
You can use hasSecurityGroups() to see if a value was sent in this field.
public final Boolean sourceDestCheck()
Indicates whether source/destination checking is enabled.
public final String spotInstanceRequestId()
If the request is a Spot Instance request, the ID of the request.
public final String sriovNetSupport()
Specifies whether enhanced networking with the Intel 82599 Virtual Function interface is enabled.
public final StateReason stateReason()
The reason for the most recent state transition.
public final boolean hasTags()
public final List<Tag> tags()
Any tags assigned to the instance.
Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.
You can use hasTags() to see if a value was sent in this field.
public final VirtualizationType virtualizationType()
The virtualization type of the instance.
If the service returns an enum value that is not available in the current SDK version,
virtualizationType will return VirtualizationType.UNKNOWN_TO_SDK_VERSION. The raw value returned
by the service is available from virtualizationTypeAsString().
VirtualizationTypepublic final String virtualizationTypeAsString()
The virtualization type of the instance.
If the service returns an enum value that is not available in the current SDK version,
virtualizationType will return VirtualizationType.UNKNOWN_TO_SDK_VERSION. The raw value returned
by the service is available from virtualizationTypeAsString().
VirtualizationTypepublic final CpuOptions cpuOptions()
The CPU options for the instance.
public final String capacityReservationId()
The ID of the Capacity Reservation.
public final CapacityReservationSpecificationResponse capacityReservationSpecification()
Information about the Capacity Reservation targeting option.
public final HibernationOptions hibernationOptions()
Indicates whether the instance is enabled for hibernation.
public final boolean hasLicenses()
public final List<LicenseConfiguration> licenses()
The license configurations.
Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.
You can use hasLicenses() to see if a value was sent in this field.
public final InstanceMetadataOptionsResponse metadataOptions()
The metadata options for the instance.
public final EnclaveOptions enclaveOptions()
Indicates whether the instance is enabled for AWS Nitro Enclaves.
public final BootModeValues bootMode()
The boot mode of the instance. For more information, see Boot modes in the Amazon EC2 User Guide.
If the service returns an enum value that is not available in the current SDK version, bootMode will
return BootModeValues.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available from
bootModeAsString().
BootModeValuespublic final String bootModeAsString()
The boot mode of the instance. For more information, see Boot modes in the Amazon EC2 User Guide.
If the service returns an enum value that is not available in the current SDK version, bootMode will
return BootModeValues.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available from
bootModeAsString().
BootModeValuespublic Instance.Builder toBuilder()
toBuilder in interface ToCopyableBuilder<Instance.Builder,Instance>public static Instance.Builder builder()
public static Class<? extends Instance.Builder> serializableBuilderClass()
public final boolean equalsBySdkFields(Object obj)
equalsBySdkFields in interface SdkPojopublic final String toString()
Copyright © 2021. All rights reserved.