com.amazonaws.services.securityhub.model.AwsEc2LaunchTemplateDataDetails Maven / Gradle / Ivy
Show all versions of aws-java-sdk-securityhub Show documentation
/*
* Copyright 2018-2023 Amazon.com, Inc. or its affiliates. All Rights Reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance with
* the License. A copy of the License is located at
*
* http://aws.amazon.com/apache2.0
*
* or in the "license" file accompanying this file. This file is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
* CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions
* and limitations under the License.
*/
package com.amazonaws.services.securityhub.model;
import java.io.Serializable;
import javax.annotation.Generated;
import com.amazonaws.protocol.StructuredPojo;
import com.amazonaws.protocol.ProtocolMarshaller;
/**
*
* The information to include in an Amazon Elastic Compute Cloud (Amazon EC2) launch template.
*
*
* @see AWS API Documentation
*/
@Generated("com.amazonaws:aws-java-sdk-code-generator")
public class AwsEc2LaunchTemplateDataDetails implements Serializable, Cloneable, StructuredPojo {
/**
*
* Information about a block device mapping for an Amazon EC2 launch template.
*
*/
private java.util.List blockDeviceMappingSet;
/**
*
* Specifies an instance's Capacity Reservation targeting option. You can specify only one option at a time.
*
*/
private AwsEc2LaunchTemplateDataCapacityReservationSpecificationDetails capacityReservationSpecification;
/**
*
* Specifies the CPU options for an instance. For more information, see Optimize CPU options in
* the Amazon Elastic Compute Cloud User Guide.
*
*/
private AwsEc2LaunchTemplateDataCpuOptionsDetails cpuOptions;
/**
*
* Specifies the credit option for CPU usage of a T2, T3, or T3a instance.
*
*/
private AwsEc2LaunchTemplateDataCreditSpecificationDetails creditSpecification;
/**
*
* Indicates whether to enable the instance for stop protection. For more information, see Enable stop
* protection in the Amazon EC2 User Guide.
*
*/
private Boolean disableApiStop;
/**
*
* If you set this parameter to true
, you can't terminate the instance using the Amazon EC2 console,
* CLI, or API. If set to true
, you can.
*
*/
private Boolean disableApiTermination;
/**
*
* Indicates whether the instance is optimized for Amazon EBS I/O.
*
*/
private Boolean ebsOptimized;
/**
*
* Provides details about Elastic Graphics accelerators to associate with the instance.
*
*/
private java.util.List elasticGpuSpecificationSet;
/**
*
* The Amazon Elastic Inference accelerator for the instance.
*
*/
private java.util.List elasticInferenceAcceleratorSet;
/**
*
* Indicates whether the Amazon EC2 instance is enabled for Amazon Web Services Nitro Enclaves.
*
*/
private AwsEc2LaunchTemplateDataEnclaveOptionsDetails enclaveOptions;
/**
*
* Specifies whether your Amazon EC2 instance is configured for hibernation.
*
*/
private AwsEc2LaunchTemplateDataHibernationOptionsDetails hibernationOptions;
/**
*
* The name or Amazon Resource Name (ARN) of an IAM instance profile.
*
*/
private AwsEc2LaunchTemplateDataIamInstanceProfileDetails iamInstanceProfile;
/**
*
* The ID of the Amazon Machine Image (AMI).
*
*/
private String imageId;
/**
*
* Provides the options for specifying the instance initiated shutdown behavior.
*
*/
private String instanceInitiatedShutdownBehavior;
/**
*
* Specifies the market (purchasing) option for an instance.
*
*/
private AwsEc2LaunchTemplateDataInstanceMarketOptionsDetails instanceMarketOptions;
/**
*
* The attributes for the instance types. When you specify instance attributes, Amazon EC2 will identify instance
* types with these attributes. If you specify InstanceRequirements
, you can't specify
* InstanceType
.
*
*/
private AwsEc2LaunchTemplateDataInstanceRequirementsDetails instanceRequirements;
/**
*
* The instance type. For more information, see Instance types in the
* Amazon EC2 User Guide. If you specify InstanceType
, you can't specify
* InstanceRequirements
.
*
*/
private String instanceType;
/**
*
* The ID of the kernel.
*
*/
private String kernelId;
/**
*
* The name of the key pair that allows users to connect to the instance.
*
*/
private String keyName;
/**
*
* Specifies a license configuration for an instance.
*
*/
private java.util.List licenseSet;
/**
*
* The maintenance options of your instance.
*
*/
private AwsEc2LaunchTemplateDataMaintenanceOptionsDetails maintenanceOptions;
/**
*
* The metadata options for the instance. For more information, see Instance metadata and user
* data in the Amazon EC2 User Guide.
*
*/
private AwsEc2LaunchTemplateDataMetadataOptionsDetails metadataOptions;
/**
*
* The monitoring for the instance.
*
*/
private AwsEc2LaunchTemplateDataMonitoringDetails monitoring;
/**
*
* Specifies the parameters for a network interface that is attached to the instance.
*
*/
private java.util.List networkInterfaceSet;
/**
*
* Specifies the placement of an instance.
*
*/
private AwsEc2LaunchTemplateDataPlacementDetails placement;
/**
*
* The options for the instance hostname.
*
*/
private AwsEc2LaunchTemplateDataPrivateDnsNameOptionsDetails privateDnsNameOptions;
/**
*
* The ID of the RAM disk.
*
*/
private String ramDiskId;
/**
*
* One or more security group IDs.
*
*/
private java.util.List securityGroupIdSet;
/**
*
* One or more security group names. For a nondefault VPC, you must use security group IDs instead. You cannot
* specify both a security group ID and security name in the same request.
*
*/
private java.util.List securityGroupSet;
/**
*
* The user data to make available to the instance.
*
*/
private String userData;
/**
*
* Information about a block device mapping for an Amazon EC2 launch template.
*
*
* @return Information about a block device mapping for an Amazon EC2 launch template.
*/
public java.util.List getBlockDeviceMappingSet() {
return blockDeviceMappingSet;
}
/**
*
* Information about a block device mapping for an Amazon EC2 launch template.
*
*
* @param blockDeviceMappingSet
* Information about a block device mapping for an Amazon EC2 launch template.
*/
public void setBlockDeviceMappingSet(java.util.Collection blockDeviceMappingSet) {
if (blockDeviceMappingSet == null) {
this.blockDeviceMappingSet = null;
return;
}
this.blockDeviceMappingSet = new java.util.ArrayList(blockDeviceMappingSet);
}
/**
*
* Information about a block device mapping for an Amazon EC2 launch template.
*
*
* NOTE: This method appends the values to the existing list (if any). Use
* {@link #setBlockDeviceMappingSet(java.util.Collection)} or
* {@link #withBlockDeviceMappingSet(java.util.Collection)} if you want to override the existing values.
*
*
* @param blockDeviceMappingSet
* Information about a block device mapping for an Amazon EC2 launch template.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsEc2LaunchTemplateDataDetails withBlockDeviceMappingSet(AwsEc2LaunchTemplateDataBlockDeviceMappingSetDetails... blockDeviceMappingSet) {
if (this.blockDeviceMappingSet == null) {
setBlockDeviceMappingSet(new java.util.ArrayList(blockDeviceMappingSet.length));
}
for (AwsEc2LaunchTemplateDataBlockDeviceMappingSetDetails ele : blockDeviceMappingSet) {
this.blockDeviceMappingSet.add(ele);
}
return this;
}
/**
*
* Information about a block device mapping for an Amazon EC2 launch template.
*
*
* @param blockDeviceMappingSet
* Information about a block device mapping for an Amazon EC2 launch template.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsEc2LaunchTemplateDataDetails withBlockDeviceMappingSet(
java.util.Collection blockDeviceMappingSet) {
setBlockDeviceMappingSet(blockDeviceMappingSet);
return this;
}
/**
*
* Specifies an instance's Capacity Reservation targeting option. You can specify only one option at a time.
*
*
* @param capacityReservationSpecification
* Specifies an instance's Capacity Reservation targeting option. You can specify only one option at a time.
*/
public void setCapacityReservationSpecification(AwsEc2LaunchTemplateDataCapacityReservationSpecificationDetails capacityReservationSpecification) {
this.capacityReservationSpecification = capacityReservationSpecification;
}
/**
*
* Specifies an instance's Capacity Reservation targeting option. You can specify only one option at a time.
*
*
* @return Specifies an instance's Capacity Reservation targeting option. You can specify only one option at a time.
*/
public AwsEc2LaunchTemplateDataCapacityReservationSpecificationDetails getCapacityReservationSpecification() {
return this.capacityReservationSpecification;
}
/**
*
* Specifies an instance's Capacity Reservation targeting option. You can specify only one option at a time.
*
*
* @param capacityReservationSpecification
* Specifies an instance's Capacity Reservation targeting option. You can specify only one option at a time.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsEc2LaunchTemplateDataDetails withCapacityReservationSpecification(
AwsEc2LaunchTemplateDataCapacityReservationSpecificationDetails capacityReservationSpecification) {
setCapacityReservationSpecification(capacityReservationSpecification);
return this;
}
/**
*
* Specifies the CPU options for an instance. For more information, see Optimize CPU options in
* the Amazon Elastic Compute Cloud User Guide.
*
*
* @param cpuOptions
* Specifies the CPU options for an instance. For more information, see Optimize CPU
* options in the Amazon Elastic Compute Cloud User Guide.
*/
public void setCpuOptions(AwsEc2LaunchTemplateDataCpuOptionsDetails cpuOptions) {
this.cpuOptions = cpuOptions;
}
/**
*
* Specifies the CPU options for an instance. For more information, see Optimize CPU options in
* the Amazon Elastic Compute Cloud User Guide.
*
*
* @return Specifies the CPU options for an instance. For more information, see Optimize CPU
* options in the Amazon Elastic Compute Cloud User Guide.
*/
public AwsEc2LaunchTemplateDataCpuOptionsDetails getCpuOptions() {
return this.cpuOptions;
}
/**
*
* Specifies the CPU options for an instance. For more information, see Optimize CPU options in
* the Amazon Elastic Compute Cloud User Guide.
*
*
* @param cpuOptions
* Specifies the CPU options for an instance. For more information, see Optimize CPU
* options in the Amazon Elastic Compute Cloud User Guide.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsEc2LaunchTemplateDataDetails withCpuOptions(AwsEc2LaunchTemplateDataCpuOptionsDetails cpuOptions) {
setCpuOptions(cpuOptions);
return this;
}
/**
*
* Specifies the credit option for CPU usage of a T2, T3, or T3a instance.
*
*
* @param creditSpecification
* Specifies the credit option for CPU usage of a T2, T3, or T3a instance.
*/
public void setCreditSpecification(AwsEc2LaunchTemplateDataCreditSpecificationDetails creditSpecification) {
this.creditSpecification = creditSpecification;
}
/**
*
* Specifies the credit option for CPU usage of a T2, T3, or T3a instance.
*
*
* @return Specifies the credit option for CPU usage of a T2, T3, or T3a instance.
*/
public AwsEc2LaunchTemplateDataCreditSpecificationDetails getCreditSpecification() {
return this.creditSpecification;
}
/**
*
* Specifies the credit option for CPU usage of a T2, T3, or T3a instance.
*
*
* @param creditSpecification
* Specifies the credit option for CPU usage of a T2, T3, or T3a instance.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsEc2LaunchTemplateDataDetails withCreditSpecification(AwsEc2LaunchTemplateDataCreditSpecificationDetails creditSpecification) {
setCreditSpecification(creditSpecification);
return this;
}
/**
*
* Indicates whether to enable the instance for stop protection. For more information, see Enable stop
* protection in the Amazon EC2 User Guide.
*
*
* @param disableApiStop
* Indicates whether to enable the instance for stop protection. For more information, see Enable
* stop protection in the Amazon EC2 User Guide.
*/
public void setDisableApiStop(Boolean disableApiStop) {
this.disableApiStop = disableApiStop;
}
/**
*
* Indicates whether to enable the instance for stop protection. For more information, see Enable stop
* protection in the Amazon EC2 User Guide.
*
*
* @return Indicates whether to enable the instance for stop protection. For more information, see Enable
* stop protection in the Amazon EC2 User Guide.
*/
public Boolean getDisableApiStop() {
return this.disableApiStop;
}
/**
*
* Indicates whether to enable the instance for stop protection. For more information, see Enable stop
* protection in the Amazon EC2 User Guide.
*
*
* @param disableApiStop
* Indicates whether to enable the instance for stop protection. For more information, see Enable
* stop protection in the Amazon EC2 User Guide.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsEc2LaunchTemplateDataDetails withDisableApiStop(Boolean disableApiStop) {
setDisableApiStop(disableApiStop);
return this;
}
/**
*
* Indicates whether to enable the instance for stop protection. For more information, see Enable stop
* protection in the Amazon EC2 User Guide.
*
*
* @return Indicates whether to enable the instance for stop protection. For more information, see Enable
* stop protection in the Amazon EC2 User Guide.
*/
public Boolean isDisableApiStop() {
return this.disableApiStop;
}
/**
*
* If you set this parameter to true
, you can't terminate the instance using the Amazon EC2 console,
* CLI, or API. If set to true
, you can.
*
*
* @param disableApiTermination
* If you set this parameter to true
, you can't terminate the instance using the Amazon EC2
* console, CLI, or API. If set to true
, you can.
*/
public void setDisableApiTermination(Boolean disableApiTermination) {
this.disableApiTermination = disableApiTermination;
}
/**
*
* If you set this parameter to true
, you can't terminate the instance using the Amazon EC2 console,
* CLI, or API. If set to true
, you can.
*
*
* @return If you set this parameter to true
, you can't terminate the instance using the Amazon EC2
* console, CLI, or API. If set to true
, you can.
*/
public Boolean getDisableApiTermination() {
return this.disableApiTermination;
}
/**
*
* If you set this parameter to true
, you can't terminate the instance using the Amazon EC2 console,
* CLI, or API. If set to true
, you can.
*
*
* @param disableApiTermination
* If you set this parameter to true
, you can't terminate the instance using the Amazon EC2
* console, CLI, or API. If set to true
, you can.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsEc2LaunchTemplateDataDetails withDisableApiTermination(Boolean disableApiTermination) {
setDisableApiTermination(disableApiTermination);
return this;
}
/**
*
* If you set this parameter to true
, you can't terminate the instance using the Amazon EC2 console,
* CLI, or API. If set to true
, you can.
*
*
* @return If you set this parameter to true
, you can't terminate the instance using the Amazon EC2
* console, CLI, or API. If set to true
, you can.
*/
public Boolean isDisableApiTermination() {
return this.disableApiTermination;
}
/**
*
* Indicates whether the instance is optimized for Amazon EBS I/O.
*
*
* @param ebsOptimized
* Indicates whether the instance is optimized for Amazon EBS I/O.
*/
public void setEbsOptimized(Boolean ebsOptimized) {
this.ebsOptimized = ebsOptimized;
}
/**
*
* Indicates whether the instance is optimized for Amazon EBS I/O.
*
*
* @return Indicates whether the instance is optimized for Amazon EBS I/O.
*/
public Boolean getEbsOptimized() {
return this.ebsOptimized;
}
/**
*
* Indicates whether the instance is optimized for Amazon EBS I/O.
*
*
* @param ebsOptimized
* Indicates whether the instance is optimized for Amazon EBS I/O.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsEc2LaunchTemplateDataDetails withEbsOptimized(Boolean ebsOptimized) {
setEbsOptimized(ebsOptimized);
return this;
}
/**
*
* Indicates whether the instance is optimized for Amazon EBS I/O.
*
*
* @return Indicates whether the instance is optimized for Amazon EBS I/O.
*/
public Boolean isEbsOptimized() {
return this.ebsOptimized;
}
/**
*
* Provides details about Elastic Graphics accelerators to associate with the instance.
*
*
* @return Provides details about Elastic Graphics accelerators to associate with the instance.
*/
public java.util.List getElasticGpuSpecificationSet() {
return elasticGpuSpecificationSet;
}
/**
*
* Provides details about Elastic Graphics accelerators to associate with the instance.
*
*
* @param elasticGpuSpecificationSet
* Provides details about Elastic Graphics accelerators to associate with the instance.
*/
public void setElasticGpuSpecificationSet(java.util.Collection elasticGpuSpecificationSet) {
if (elasticGpuSpecificationSet == null) {
this.elasticGpuSpecificationSet = null;
return;
}
this.elasticGpuSpecificationSet = new java.util.ArrayList(elasticGpuSpecificationSet);
}
/**
*
* Provides details about Elastic Graphics accelerators to associate with the instance.
*
*
* NOTE: This method appends the values to the existing list (if any). Use
* {@link #setElasticGpuSpecificationSet(java.util.Collection)} or
* {@link #withElasticGpuSpecificationSet(java.util.Collection)} if you want to override the existing values.
*
*
* @param elasticGpuSpecificationSet
* Provides details about Elastic Graphics accelerators to associate with the instance.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsEc2LaunchTemplateDataDetails withElasticGpuSpecificationSet(
AwsEc2LaunchTemplateDataElasticGpuSpecificationSetDetails... elasticGpuSpecificationSet) {
if (this.elasticGpuSpecificationSet == null) {
setElasticGpuSpecificationSet(new java.util.ArrayList(elasticGpuSpecificationSet.length));
}
for (AwsEc2LaunchTemplateDataElasticGpuSpecificationSetDetails ele : elasticGpuSpecificationSet) {
this.elasticGpuSpecificationSet.add(ele);
}
return this;
}
/**
*
* Provides details about Elastic Graphics accelerators to associate with the instance.
*
*
* @param elasticGpuSpecificationSet
* Provides details about Elastic Graphics accelerators to associate with the instance.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsEc2LaunchTemplateDataDetails withElasticGpuSpecificationSet(
java.util.Collection elasticGpuSpecificationSet) {
setElasticGpuSpecificationSet(elasticGpuSpecificationSet);
return this;
}
/**
*
* The Amazon Elastic Inference accelerator for the instance.
*
*
* @return The Amazon Elastic Inference accelerator for the instance.
*/
public java.util.List getElasticInferenceAcceleratorSet() {
return elasticInferenceAcceleratorSet;
}
/**
*
* The Amazon Elastic Inference accelerator for the instance.
*
*
* @param elasticInferenceAcceleratorSet
* The Amazon Elastic Inference accelerator for the instance.
*/
public void setElasticInferenceAcceleratorSet(
java.util.Collection elasticInferenceAcceleratorSet) {
if (elasticInferenceAcceleratorSet == null) {
this.elasticInferenceAcceleratorSet = null;
return;
}
this.elasticInferenceAcceleratorSet = new java.util.ArrayList(
elasticInferenceAcceleratorSet);
}
/**
*
* The Amazon Elastic Inference accelerator for the instance.
*
*
* NOTE: This method appends the values to the existing list (if any). Use
* {@link #setElasticInferenceAcceleratorSet(java.util.Collection)} or
* {@link #withElasticInferenceAcceleratorSet(java.util.Collection)} if you want to override the existing values.
*
*
* @param elasticInferenceAcceleratorSet
* The Amazon Elastic Inference accelerator for the instance.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsEc2LaunchTemplateDataDetails withElasticInferenceAcceleratorSet(
AwsEc2LaunchTemplateDataElasticInferenceAcceleratorSetDetails... elasticInferenceAcceleratorSet) {
if (this.elasticInferenceAcceleratorSet == null) {
setElasticInferenceAcceleratorSet(new java.util.ArrayList(
elasticInferenceAcceleratorSet.length));
}
for (AwsEc2LaunchTemplateDataElasticInferenceAcceleratorSetDetails ele : elasticInferenceAcceleratorSet) {
this.elasticInferenceAcceleratorSet.add(ele);
}
return this;
}
/**
*
* The Amazon Elastic Inference accelerator for the instance.
*
*
* @param elasticInferenceAcceleratorSet
* The Amazon Elastic Inference accelerator for the instance.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsEc2LaunchTemplateDataDetails withElasticInferenceAcceleratorSet(
java.util.Collection elasticInferenceAcceleratorSet) {
setElasticInferenceAcceleratorSet(elasticInferenceAcceleratorSet);
return this;
}
/**
*
* Indicates whether the Amazon EC2 instance is enabled for Amazon Web Services Nitro Enclaves.
*
*
* @param enclaveOptions
* Indicates whether the Amazon EC2 instance is enabled for Amazon Web Services Nitro Enclaves.
*/
public void setEnclaveOptions(AwsEc2LaunchTemplateDataEnclaveOptionsDetails enclaveOptions) {
this.enclaveOptions = enclaveOptions;
}
/**
*
* Indicates whether the Amazon EC2 instance is enabled for Amazon Web Services Nitro Enclaves.
*
*
* @return Indicates whether the Amazon EC2 instance is enabled for Amazon Web Services Nitro Enclaves.
*/
public AwsEc2LaunchTemplateDataEnclaveOptionsDetails getEnclaveOptions() {
return this.enclaveOptions;
}
/**
*
* Indicates whether the Amazon EC2 instance is enabled for Amazon Web Services Nitro Enclaves.
*
*
* @param enclaveOptions
* Indicates whether the Amazon EC2 instance is enabled for Amazon Web Services Nitro Enclaves.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsEc2LaunchTemplateDataDetails withEnclaveOptions(AwsEc2LaunchTemplateDataEnclaveOptionsDetails enclaveOptions) {
setEnclaveOptions(enclaveOptions);
return this;
}
/**
*
* Specifies whether your Amazon EC2 instance is configured for hibernation.
*
*
* @param hibernationOptions
* Specifies whether your Amazon EC2 instance is configured for hibernation.
*/
public void setHibernationOptions(AwsEc2LaunchTemplateDataHibernationOptionsDetails hibernationOptions) {
this.hibernationOptions = hibernationOptions;
}
/**
*
* Specifies whether your Amazon EC2 instance is configured for hibernation.
*
*
* @return Specifies whether your Amazon EC2 instance is configured for hibernation.
*/
public AwsEc2LaunchTemplateDataHibernationOptionsDetails getHibernationOptions() {
return this.hibernationOptions;
}
/**
*
* Specifies whether your Amazon EC2 instance is configured for hibernation.
*
*
* @param hibernationOptions
* Specifies whether your Amazon EC2 instance is configured for hibernation.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsEc2LaunchTemplateDataDetails withHibernationOptions(AwsEc2LaunchTemplateDataHibernationOptionsDetails hibernationOptions) {
setHibernationOptions(hibernationOptions);
return this;
}
/**
*
* The name or Amazon Resource Name (ARN) of an IAM instance profile.
*
*
* @param iamInstanceProfile
* The name or Amazon Resource Name (ARN) of an IAM instance profile.
*/
public void setIamInstanceProfile(AwsEc2LaunchTemplateDataIamInstanceProfileDetails iamInstanceProfile) {
this.iamInstanceProfile = iamInstanceProfile;
}
/**
*
* The name or Amazon Resource Name (ARN) of an IAM instance profile.
*
*
* @return The name or Amazon Resource Name (ARN) of an IAM instance profile.
*/
public AwsEc2LaunchTemplateDataIamInstanceProfileDetails getIamInstanceProfile() {
return this.iamInstanceProfile;
}
/**
*
* The name or Amazon Resource Name (ARN) of an IAM instance profile.
*
*
* @param iamInstanceProfile
* The name or Amazon Resource Name (ARN) of an IAM instance profile.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsEc2LaunchTemplateDataDetails withIamInstanceProfile(AwsEc2LaunchTemplateDataIamInstanceProfileDetails iamInstanceProfile) {
setIamInstanceProfile(iamInstanceProfile);
return this;
}
/**
*
* The ID of the Amazon Machine Image (AMI).
*
*
* @param imageId
* The ID of the Amazon Machine Image (AMI).
*/
public void setImageId(String imageId) {
this.imageId = imageId;
}
/**
*
* The ID of the Amazon Machine Image (AMI).
*
*
* @return The ID of the Amazon Machine Image (AMI).
*/
public String getImageId() {
return this.imageId;
}
/**
*
* The ID of the Amazon Machine Image (AMI).
*
*
* @param imageId
* The ID of the Amazon Machine Image (AMI).
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsEc2LaunchTemplateDataDetails withImageId(String imageId) {
setImageId(imageId);
return this;
}
/**
*
* Provides the options for specifying the instance initiated shutdown behavior.
*
*
* @param instanceInitiatedShutdownBehavior
* Provides the options for specifying the instance initiated shutdown behavior.
*/
public void setInstanceInitiatedShutdownBehavior(String instanceInitiatedShutdownBehavior) {
this.instanceInitiatedShutdownBehavior = instanceInitiatedShutdownBehavior;
}
/**
*
* Provides the options for specifying the instance initiated shutdown behavior.
*
*
* @return Provides the options for specifying the instance initiated shutdown behavior.
*/
public String getInstanceInitiatedShutdownBehavior() {
return this.instanceInitiatedShutdownBehavior;
}
/**
*
* Provides the options for specifying the instance initiated shutdown behavior.
*
*
* @param instanceInitiatedShutdownBehavior
* Provides the options for specifying the instance initiated shutdown behavior.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsEc2LaunchTemplateDataDetails withInstanceInitiatedShutdownBehavior(String instanceInitiatedShutdownBehavior) {
setInstanceInitiatedShutdownBehavior(instanceInitiatedShutdownBehavior);
return this;
}
/**
*
* Specifies the market (purchasing) option for an instance.
*
*
* @param instanceMarketOptions
* Specifies the market (purchasing) option for an instance.
*/
public void setInstanceMarketOptions(AwsEc2LaunchTemplateDataInstanceMarketOptionsDetails instanceMarketOptions) {
this.instanceMarketOptions = instanceMarketOptions;
}
/**
*
* Specifies the market (purchasing) option for an instance.
*
*
* @return Specifies the market (purchasing) option for an instance.
*/
public AwsEc2LaunchTemplateDataInstanceMarketOptionsDetails getInstanceMarketOptions() {
return this.instanceMarketOptions;
}
/**
*
* Specifies the market (purchasing) option for an instance.
*
*
* @param instanceMarketOptions
* Specifies the market (purchasing) option for an instance.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsEc2LaunchTemplateDataDetails withInstanceMarketOptions(AwsEc2LaunchTemplateDataInstanceMarketOptionsDetails instanceMarketOptions) {
setInstanceMarketOptions(instanceMarketOptions);
return this;
}
/**
*
* The attributes for the instance types. When you specify instance attributes, Amazon EC2 will identify instance
* types with these attributes. If you specify InstanceRequirements
, you can't specify
* InstanceType
.
*
*
* @param instanceRequirements
* The attributes for the instance types. When you specify instance attributes, Amazon EC2 will identify
* instance types with these attributes. If you specify InstanceRequirements
, you can't specify
* InstanceType
.
*/
public void setInstanceRequirements(AwsEc2LaunchTemplateDataInstanceRequirementsDetails instanceRequirements) {
this.instanceRequirements = instanceRequirements;
}
/**
*
* The attributes for the instance types. When you specify instance attributes, Amazon EC2 will identify instance
* types with these attributes. If you specify InstanceRequirements
, you can't specify
* InstanceType
.
*
*
* @return The attributes for the instance types. When you specify instance attributes, Amazon EC2 will identify
* instance types with these attributes. If you specify InstanceRequirements
, you can't specify
* InstanceType
.
*/
public AwsEc2LaunchTemplateDataInstanceRequirementsDetails getInstanceRequirements() {
return this.instanceRequirements;
}
/**
*
* The attributes for the instance types. When you specify instance attributes, Amazon EC2 will identify instance
* types with these attributes. If you specify InstanceRequirements
, you can't specify
* InstanceType
.
*
*
* @param instanceRequirements
* The attributes for the instance types. When you specify instance attributes, Amazon EC2 will identify
* instance types with these attributes. If you specify InstanceRequirements
, you can't specify
* InstanceType
.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsEc2LaunchTemplateDataDetails withInstanceRequirements(AwsEc2LaunchTemplateDataInstanceRequirementsDetails instanceRequirements) {
setInstanceRequirements(instanceRequirements);
return this;
}
/**
*
* The instance type. For more information, see Instance types in the
* Amazon EC2 User Guide. If you specify InstanceType
, you can't specify
* InstanceRequirements
.
*
*
* @param instanceType
* The instance type. For more information, see Instance types in the
* Amazon EC2 User Guide. If you specify InstanceType
, you can't specify
* InstanceRequirements
.
*/
public void setInstanceType(String instanceType) {
this.instanceType = instanceType;
}
/**
*
* The instance type. For more information, see Instance types in the
* Amazon EC2 User Guide. If you specify InstanceType
, you can't specify
* InstanceRequirements
.
*
*
* @return The instance type. For more information, see Instance types in the
* Amazon EC2 User Guide. If you specify InstanceType
, you can't specify
* InstanceRequirements
.
*/
public String getInstanceType() {
return this.instanceType;
}
/**
*
* The instance type. For more information, see Instance types in the
* Amazon EC2 User Guide. If you specify InstanceType
, you can't specify
* InstanceRequirements
.
*
*
* @param instanceType
* The instance type. For more information, see Instance types in the
* Amazon EC2 User Guide. If you specify InstanceType
, you can't specify
* InstanceRequirements
.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsEc2LaunchTemplateDataDetails withInstanceType(String instanceType) {
setInstanceType(instanceType);
return this;
}
/**
*
* The ID of the kernel.
*
*
* @param kernelId
* The ID of the kernel.
*/
public void setKernelId(String kernelId) {
this.kernelId = kernelId;
}
/**
*
* The ID of the kernel.
*
*
* @return The ID of the kernel.
*/
public String getKernelId() {
return this.kernelId;
}
/**
*
* The ID of the kernel.
*
*
* @param kernelId
* The ID of the kernel.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsEc2LaunchTemplateDataDetails withKernelId(String kernelId) {
setKernelId(kernelId);
return this;
}
/**
*
* The name of the key pair that allows users to connect to the instance.
*
*
* @param keyName
* The name of the key pair that allows users to connect to the instance.
*/
public void setKeyName(String keyName) {
this.keyName = keyName;
}
/**
*
* The name of the key pair that allows users to connect to the instance.
*
*
* @return The name of the key pair that allows users to connect to the instance.
*/
public String getKeyName() {
return this.keyName;
}
/**
*
* The name of the key pair that allows users to connect to the instance.
*
*
* @param keyName
* The name of the key pair that allows users to connect to the instance.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsEc2LaunchTemplateDataDetails withKeyName(String keyName) {
setKeyName(keyName);
return this;
}
/**
*
* Specifies a license configuration for an instance.
*
*
* @return Specifies a license configuration for an instance.
*/
public java.util.List getLicenseSet() {
return licenseSet;
}
/**
*
* Specifies a license configuration for an instance.
*
*
* @param licenseSet
* Specifies a license configuration for an instance.
*/
public void setLicenseSet(java.util.Collection licenseSet) {
if (licenseSet == null) {
this.licenseSet = null;
return;
}
this.licenseSet = new java.util.ArrayList(licenseSet);
}
/**
*
* Specifies a license configuration for an instance.
*
*
* NOTE: This method appends the values to the existing list (if any). Use
* {@link #setLicenseSet(java.util.Collection)} or {@link #withLicenseSet(java.util.Collection)} if you want to
* override the existing values.
*
*
* @param licenseSet
* Specifies a license configuration for an instance.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsEc2LaunchTemplateDataDetails withLicenseSet(AwsEc2LaunchTemplateDataLicenseSetDetails... licenseSet) {
if (this.licenseSet == null) {
setLicenseSet(new java.util.ArrayList(licenseSet.length));
}
for (AwsEc2LaunchTemplateDataLicenseSetDetails ele : licenseSet) {
this.licenseSet.add(ele);
}
return this;
}
/**
*
* Specifies a license configuration for an instance.
*
*
* @param licenseSet
* Specifies a license configuration for an instance.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsEc2LaunchTemplateDataDetails withLicenseSet(java.util.Collection licenseSet) {
setLicenseSet(licenseSet);
return this;
}
/**
*
* The maintenance options of your instance.
*
*
* @param maintenanceOptions
* The maintenance options of your instance.
*/
public void setMaintenanceOptions(AwsEc2LaunchTemplateDataMaintenanceOptionsDetails maintenanceOptions) {
this.maintenanceOptions = maintenanceOptions;
}
/**
*
* The maintenance options of your instance.
*
*
* @return The maintenance options of your instance.
*/
public AwsEc2LaunchTemplateDataMaintenanceOptionsDetails getMaintenanceOptions() {
return this.maintenanceOptions;
}
/**
*
* The maintenance options of your instance.
*
*
* @param maintenanceOptions
* The maintenance options of your instance.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsEc2LaunchTemplateDataDetails withMaintenanceOptions(AwsEc2LaunchTemplateDataMaintenanceOptionsDetails maintenanceOptions) {
setMaintenanceOptions(maintenanceOptions);
return this;
}
/**
*
* The metadata options for the instance. For more information, see Instance metadata and user
* data in the Amazon EC2 User Guide.
*
*
* @param metadataOptions
* The metadata options for the instance. For more information, see Instance metadata
* and user data in the Amazon EC2 User Guide.
*/
public void setMetadataOptions(AwsEc2LaunchTemplateDataMetadataOptionsDetails metadataOptions) {
this.metadataOptions = metadataOptions;
}
/**
*
* The metadata options for the instance. For more information, see Instance metadata and user
* data in the Amazon EC2 User Guide.
*
*
* @return The metadata options for the instance. For more information, see Instance metadata
* and user data in the Amazon EC2 User Guide.
*/
public AwsEc2LaunchTemplateDataMetadataOptionsDetails getMetadataOptions() {
return this.metadataOptions;
}
/**
*
* The metadata options for the instance. For more information, see Instance metadata and user
* data in the Amazon EC2 User Guide.
*
*
* @param metadataOptions
* The metadata options for the instance. For more information, see Instance metadata
* and user data in the Amazon EC2 User Guide.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsEc2LaunchTemplateDataDetails withMetadataOptions(AwsEc2LaunchTemplateDataMetadataOptionsDetails metadataOptions) {
setMetadataOptions(metadataOptions);
return this;
}
/**
*
* The monitoring for the instance.
*
*
* @param monitoring
* The monitoring for the instance.
*/
public void setMonitoring(AwsEc2LaunchTemplateDataMonitoringDetails monitoring) {
this.monitoring = monitoring;
}
/**
*
* The monitoring for the instance.
*
*
* @return The monitoring for the instance.
*/
public AwsEc2LaunchTemplateDataMonitoringDetails getMonitoring() {
return this.monitoring;
}
/**
*
* The monitoring for the instance.
*
*
* @param monitoring
* The monitoring for the instance.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsEc2LaunchTemplateDataDetails withMonitoring(AwsEc2LaunchTemplateDataMonitoringDetails monitoring) {
setMonitoring(monitoring);
return this;
}
/**
*
* Specifies the parameters for a network interface that is attached to the instance.
*
*
* @return Specifies the parameters for a network interface that is attached to the instance.
*/
public java.util.List getNetworkInterfaceSet() {
return networkInterfaceSet;
}
/**
*
* Specifies the parameters for a network interface that is attached to the instance.
*
*
* @param networkInterfaceSet
* Specifies the parameters for a network interface that is attached to the instance.
*/
public void setNetworkInterfaceSet(java.util.Collection networkInterfaceSet) {
if (networkInterfaceSet == null) {
this.networkInterfaceSet = null;
return;
}
this.networkInterfaceSet = new java.util.ArrayList(networkInterfaceSet);
}
/**
*
* Specifies the parameters for a network interface that is attached to the instance.
*
*
* NOTE: This method appends the values to the existing list (if any). Use
* {@link #setNetworkInterfaceSet(java.util.Collection)} or {@link #withNetworkInterfaceSet(java.util.Collection)}
* if you want to override the existing values.
*
*
* @param networkInterfaceSet
* Specifies the parameters for a network interface that is attached to the instance.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsEc2LaunchTemplateDataDetails withNetworkInterfaceSet(AwsEc2LaunchTemplateDataNetworkInterfaceSetDetails... networkInterfaceSet) {
if (this.networkInterfaceSet == null) {
setNetworkInterfaceSet(new java.util.ArrayList(networkInterfaceSet.length));
}
for (AwsEc2LaunchTemplateDataNetworkInterfaceSetDetails ele : networkInterfaceSet) {
this.networkInterfaceSet.add(ele);
}
return this;
}
/**
*
* Specifies the parameters for a network interface that is attached to the instance.
*
*
* @param networkInterfaceSet
* Specifies the parameters for a network interface that is attached to the instance.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsEc2LaunchTemplateDataDetails withNetworkInterfaceSet(java.util.Collection networkInterfaceSet) {
setNetworkInterfaceSet(networkInterfaceSet);
return this;
}
/**
*
* Specifies the placement of an instance.
*
*
* @param placement
* Specifies the placement of an instance.
*/
public void setPlacement(AwsEc2LaunchTemplateDataPlacementDetails placement) {
this.placement = placement;
}
/**
*
* Specifies the placement of an instance.
*
*
* @return Specifies the placement of an instance.
*/
public AwsEc2LaunchTemplateDataPlacementDetails getPlacement() {
return this.placement;
}
/**
*
* Specifies the placement of an instance.
*
*
* @param placement
* Specifies the placement of an instance.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsEc2LaunchTemplateDataDetails withPlacement(AwsEc2LaunchTemplateDataPlacementDetails placement) {
setPlacement(placement);
return this;
}
/**
*
* The options for the instance hostname.
*
*
* @param privateDnsNameOptions
* The options for the instance hostname.
*/
public void setPrivateDnsNameOptions(AwsEc2LaunchTemplateDataPrivateDnsNameOptionsDetails privateDnsNameOptions) {
this.privateDnsNameOptions = privateDnsNameOptions;
}
/**
*
* The options for the instance hostname.
*
*
* @return The options for the instance hostname.
*/
public AwsEc2LaunchTemplateDataPrivateDnsNameOptionsDetails getPrivateDnsNameOptions() {
return this.privateDnsNameOptions;
}
/**
*
* The options for the instance hostname.
*
*
* @param privateDnsNameOptions
* The options for the instance hostname.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsEc2LaunchTemplateDataDetails withPrivateDnsNameOptions(AwsEc2LaunchTemplateDataPrivateDnsNameOptionsDetails privateDnsNameOptions) {
setPrivateDnsNameOptions(privateDnsNameOptions);
return this;
}
/**
*
* The ID of the RAM disk.
*
*
* @param ramDiskId
* The ID of the RAM disk.
*/
public void setRamDiskId(String ramDiskId) {
this.ramDiskId = ramDiskId;
}
/**
*
* The ID of the RAM disk.
*
*
* @return The ID of the RAM disk.
*/
public String getRamDiskId() {
return this.ramDiskId;
}
/**
*
* The ID of the RAM disk.
*
*
* @param ramDiskId
* The ID of the RAM disk.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsEc2LaunchTemplateDataDetails withRamDiskId(String ramDiskId) {
setRamDiskId(ramDiskId);
return this;
}
/**
*
* One or more security group IDs.
*
*
* @return One or more security group IDs.
*/
public java.util.List getSecurityGroupIdSet() {
return securityGroupIdSet;
}
/**
*
* One or more security group IDs.
*
*
* @param securityGroupIdSet
* One or more security group IDs.
*/
public void setSecurityGroupIdSet(java.util.Collection securityGroupIdSet) {
if (securityGroupIdSet == null) {
this.securityGroupIdSet = null;
return;
}
this.securityGroupIdSet = new java.util.ArrayList(securityGroupIdSet);
}
/**
*
* One or more security group IDs.
*
*
* NOTE: This method appends the values to the existing list (if any). Use
* {@link #setSecurityGroupIdSet(java.util.Collection)} or {@link #withSecurityGroupIdSet(java.util.Collection)} if
* you want to override the existing values.
*
*
* @param securityGroupIdSet
* One or more security group IDs.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsEc2LaunchTemplateDataDetails withSecurityGroupIdSet(String... securityGroupIdSet) {
if (this.securityGroupIdSet == null) {
setSecurityGroupIdSet(new java.util.ArrayList(securityGroupIdSet.length));
}
for (String ele : securityGroupIdSet) {
this.securityGroupIdSet.add(ele);
}
return this;
}
/**
*
* One or more security group IDs.
*
*
* @param securityGroupIdSet
* One or more security group IDs.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsEc2LaunchTemplateDataDetails withSecurityGroupIdSet(java.util.Collection securityGroupIdSet) {
setSecurityGroupIdSet(securityGroupIdSet);
return this;
}
/**
*
* One or more security group names. For a nondefault VPC, you must use security group IDs instead. You cannot
* specify both a security group ID and security name in the same request.
*
*
* @return One or more security group names. For a nondefault VPC, you must use security group IDs instead. You
* cannot specify both a security group ID and security name in the same request.
*/
public java.util.List getSecurityGroupSet() {
return securityGroupSet;
}
/**
*
* One or more security group names. For a nondefault VPC, you must use security group IDs instead. You cannot
* specify both a security group ID and security name in the same request.
*
*
* @param securityGroupSet
* One or more security group names. For a nondefault VPC, you must use security group IDs instead. You
* cannot specify both a security group ID and security name in the same request.
*/
public void setSecurityGroupSet(java.util.Collection securityGroupSet) {
if (securityGroupSet == null) {
this.securityGroupSet = null;
return;
}
this.securityGroupSet = new java.util.ArrayList(securityGroupSet);
}
/**
*
* One or more security group names. For a nondefault VPC, you must use security group IDs instead. You cannot
* specify both a security group ID and security name in the same request.
*
*
* NOTE: This method appends the values to the existing list (if any). Use
* {@link #setSecurityGroupSet(java.util.Collection)} or {@link #withSecurityGroupSet(java.util.Collection)} if you
* want to override the existing values.
*
*
* @param securityGroupSet
* One or more security group names. For a nondefault VPC, you must use security group IDs instead. You
* cannot specify both a security group ID and security name in the same request.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsEc2LaunchTemplateDataDetails withSecurityGroupSet(String... securityGroupSet) {
if (this.securityGroupSet == null) {
setSecurityGroupSet(new java.util.ArrayList(securityGroupSet.length));
}
for (String ele : securityGroupSet) {
this.securityGroupSet.add(ele);
}
return this;
}
/**
*
* One or more security group names. For a nondefault VPC, you must use security group IDs instead. You cannot
* specify both a security group ID and security name in the same request.
*
*
* @param securityGroupSet
* One or more security group names. For a nondefault VPC, you must use security group IDs instead. You
* cannot specify both a security group ID and security name in the same request.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsEc2LaunchTemplateDataDetails withSecurityGroupSet(java.util.Collection securityGroupSet) {
setSecurityGroupSet(securityGroupSet);
return this;
}
/**
*
* The user data to make available to the instance.
*
*
* @param userData
* The user data to make available to the instance.
*/
public void setUserData(String userData) {
this.userData = userData;
}
/**
*
* The user data to make available to the instance.
*
*
* @return The user data to make available to the instance.
*/
public String getUserData() {
return this.userData;
}
/**
*
* The user data to make available to the instance.
*
*
* @param userData
* The user data to make available to the instance.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsEc2LaunchTemplateDataDetails withUserData(String userData) {
setUserData(userData);
return this;
}
/**
* Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be
* redacted from this string using a placeholder value.
*
* @return A string representation of this object.
*
* @see java.lang.Object#toString()
*/
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("{");
if (getBlockDeviceMappingSet() != null)
sb.append("BlockDeviceMappingSet: ").append(getBlockDeviceMappingSet()).append(",");
if (getCapacityReservationSpecification() != null)
sb.append("CapacityReservationSpecification: ").append(getCapacityReservationSpecification()).append(",");
if (getCpuOptions() != null)
sb.append("CpuOptions: ").append(getCpuOptions()).append(",");
if (getCreditSpecification() != null)
sb.append("CreditSpecification: ").append(getCreditSpecification()).append(",");
if (getDisableApiStop() != null)
sb.append("DisableApiStop: ").append(getDisableApiStop()).append(",");
if (getDisableApiTermination() != null)
sb.append("DisableApiTermination: ").append(getDisableApiTermination()).append(",");
if (getEbsOptimized() != null)
sb.append("EbsOptimized: ").append(getEbsOptimized()).append(",");
if (getElasticGpuSpecificationSet() != null)
sb.append("ElasticGpuSpecificationSet: ").append(getElasticGpuSpecificationSet()).append(",");
if (getElasticInferenceAcceleratorSet() != null)
sb.append("ElasticInferenceAcceleratorSet: ").append(getElasticInferenceAcceleratorSet()).append(",");
if (getEnclaveOptions() != null)
sb.append("EnclaveOptions: ").append(getEnclaveOptions()).append(",");
if (getHibernationOptions() != null)
sb.append("HibernationOptions: ").append(getHibernationOptions()).append(",");
if (getIamInstanceProfile() != null)
sb.append("IamInstanceProfile: ").append(getIamInstanceProfile()).append(",");
if (getImageId() != null)
sb.append("ImageId: ").append(getImageId()).append(",");
if (getInstanceInitiatedShutdownBehavior() != null)
sb.append("InstanceInitiatedShutdownBehavior: ").append(getInstanceInitiatedShutdownBehavior()).append(",");
if (getInstanceMarketOptions() != null)
sb.append("InstanceMarketOptions: ").append(getInstanceMarketOptions()).append(",");
if (getInstanceRequirements() != null)
sb.append("InstanceRequirements: ").append(getInstanceRequirements()).append(",");
if (getInstanceType() != null)
sb.append("InstanceType: ").append(getInstanceType()).append(",");
if (getKernelId() != null)
sb.append("KernelId: ").append(getKernelId()).append(",");
if (getKeyName() != null)
sb.append("KeyName: ").append(getKeyName()).append(",");
if (getLicenseSet() != null)
sb.append("LicenseSet: ").append(getLicenseSet()).append(",");
if (getMaintenanceOptions() != null)
sb.append("MaintenanceOptions: ").append(getMaintenanceOptions()).append(",");
if (getMetadataOptions() != null)
sb.append("MetadataOptions: ").append(getMetadataOptions()).append(",");
if (getMonitoring() != null)
sb.append("Monitoring: ").append(getMonitoring()).append(",");
if (getNetworkInterfaceSet() != null)
sb.append("NetworkInterfaceSet: ").append(getNetworkInterfaceSet()).append(",");
if (getPlacement() != null)
sb.append("Placement: ").append(getPlacement()).append(",");
if (getPrivateDnsNameOptions() != null)
sb.append("PrivateDnsNameOptions: ").append(getPrivateDnsNameOptions()).append(",");
if (getRamDiskId() != null)
sb.append("RamDiskId: ").append(getRamDiskId()).append(",");
if (getSecurityGroupIdSet() != null)
sb.append("SecurityGroupIdSet: ").append(getSecurityGroupIdSet()).append(",");
if (getSecurityGroupSet() != null)
sb.append("SecurityGroupSet: ").append(getSecurityGroupSet()).append(",");
if (getUserData() != null)
sb.append("UserData: ").append(getUserData());
sb.append("}");
return sb.toString();
}
@Override
public boolean equals(Object obj) {
if (this == obj)
return true;
if (obj == null)
return false;
if (obj instanceof AwsEc2LaunchTemplateDataDetails == false)
return false;
AwsEc2LaunchTemplateDataDetails other = (AwsEc2LaunchTemplateDataDetails) obj;
if (other.getBlockDeviceMappingSet() == null ^ this.getBlockDeviceMappingSet() == null)
return false;
if (other.getBlockDeviceMappingSet() != null && other.getBlockDeviceMappingSet().equals(this.getBlockDeviceMappingSet()) == false)
return false;
if (other.getCapacityReservationSpecification() == null ^ this.getCapacityReservationSpecification() == null)
return false;
if (other.getCapacityReservationSpecification() != null
&& other.getCapacityReservationSpecification().equals(this.getCapacityReservationSpecification()) == false)
return false;
if (other.getCpuOptions() == null ^ this.getCpuOptions() == null)
return false;
if (other.getCpuOptions() != null && other.getCpuOptions().equals(this.getCpuOptions()) == false)
return false;
if (other.getCreditSpecification() == null ^ this.getCreditSpecification() == null)
return false;
if (other.getCreditSpecification() != null && other.getCreditSpecification().equals(this.getCreditSpecification()) == false)
return false;
if (other.getDisableApiStop() == null ^ this.getDisableApiStop() == null)
return false;
if (other.getDisableApiStop() != null && other.getDisableApiStop().equals(this.getDisableApiStop()) == false)
return false;
if (other.getDisableApiTermination() == null ^ this.getDisableApiTermination() == null)
return false;
if (other.getDisableApiTermination() != null && other.getDisableApiTermination().equals(this.getDisableApiTermination()) == false)
return false;
if (other.getEbsOptimized() == null ^ this.getEbsOptimized() == null)
return false;
if (other.getEbsOptimized() != null && other.getEbsOptimized().equals(this.getEbsOptimized()) == false)
return false;
if (other.getElasticGpuSpecificationSet() == null ^ this.getElasticGpuSpecificationSet() == null)
return false;
if (other.getElasticGpuSpecificationSet() != null && other.getElasticGpuSpecificationSet().equals(this.getElasticGpuSpecificationSet()) == false)
return false;
if (other.getElasticInferenceAcceleratorSet() == null ^ this.getElasticInferenceAcceleratorSet() == null)
return false;
if (other.getElasticInferenceAcceleratorSet() != null
&& other.getElasticInferenceAcceleratorSet().equals(this.getElasticInferenceAcceleratorSet()) == false)
return false;
if (other.getEnclaveOptions() == null ^ this.getEnclaveOptions() == null)
return false;
if (other.getEnclaveOptions() != null && other.getEnclaveOptions().equals(this.getEnclaveOptions()) == false)
return false;
if (other.getHibernationOptions() == null ^ this.getHibernationOptions() == null)
return false;
if (other.getHibernationOptions() != null && other.getHibernationOptions().equals(this.getHibernationOptions()) == false)
return false;
if (other.getIamInstanceProfile() == null ^ this.getIamInstanceProfile() == null)
return false;
if (other.getIamInstanceProfile() != null && other.getIamInstanceProfile().equals(this.getIamInstanceProfile()) == false)
return false;
if (other.getImageId() == null ^ this.getImageId() == null)
return false;
if (other.getImageId() != null && other.getImageId().equals(this.getImageId()) == false)
return false;
if (other.getInstanceInitiatedShutdownBehavior() == null ^ this.getInstanceInitiatedShutdownBehavior() == null)
return false;
if (other.getInstanceInitiatedShutdownBehavior() != null
&& other.getInstanceInitiatedShutdownBehavior().equals(this.getInstanceInitiatedShutdownBehavior()) == false)
return false;
if (other.getInstanceMarketOptions() == null ^ this.getInstanceMarketOptions() == null)
return false;
if (other.getInstanceMarketOptions() != null && other.getInstanceMarketOptions().equals(this.getInstanceMarketOptions()) == false)
return false;
if (other.getInstanceRequirements() == null ^ this.getInstanceRequirements() == null)
return false;
if (other.getInstanceRequirements() != null && other.getInstanceRequirements().equals(this.getInstanceRequirements()) == false)
return false;
if (other.getInstanceType() == null ^ this.getInstanceType() == null)
return false;
if (other.getInstanceType() != null && other.getInstanceType().equals(this.getInstanceType()) == false)
return false;
if (other.getKernelId() == null ^ this.getKernelId() == null)
return false;
if (other.getKernelId() != null && other.getKernelId().equals(this.getKernelId()) == false)
return false;
if (other.getKeyName() == null ^ this.getKeyName() == null)
return false;
if (other.getKeyName() != null && other.getKeyName().equals(this.getKeyName()) == false)
return false;
if (other.getLicenseSet() == null ^ this.getLicenseSet() == null)
return false;
if (other.getLicenseSet() != null && other.getLicenseSet().equals(this.getLicenseSet()) == false)
return false;
if (other.getMaintenanceOptions() == null ^ this.getMaintenanceOptions() == null)
return false;
if (other.getMaintenanceOptions() != null && other.getMaintenanceOptions().equals(this.getMaintenanceOptions()) == false)
return false;
if (other.getMetadataOptions() == null ^ this.getMetadataOptions() == null)
return false;
if (other.getMetadataOptions() != null && other.getMetadataOptions().equals(this.getMetadataOptions()) == false)
return false;
if (other.getMonitoring() == null ^ this.getMonitoring() == null)
return false;
if (other.getMonitoring() != null && other.getMonitoring().equals(this.getMonitoring()) == false)
return false;
if (other.getNetworkInterfaceSet() == null ^ this.getNetworkInterfaceSet() == null)
return false;
if (other.getNetworkInterfaceSet() != null && other.getNetworkInterfaceSet().equals(this.getNetworkInterfaceSet()) == false)
return false;
if (other.getPlacement() == null ^ this.getPlacement() == null)
return false;
if (other.getPlacement() != null && other.getPlacement().equals(this.getPlacement()) == false)
return false;
if (other.getPrivateDnsNameOptions() == null ^ this.getPrivateDnsNameOptions() == null)
return false;
if (other.getPrivateDnsNameOptions() != null && other.getPrivateDnsNameOptions().equals(this.getPrivateDnsNameOptions()) == false)
return false;
if (other.getRamDiskId() == null ^ this.getRamDiskId() == null)
return false;
if (other.getRamDiskId() != null && other.getRamDiskId().equals(this.getRamDiskId()) == false)
return false;
if (other.getSecurityGroupIdSet() == null ^ this.getSecurityGroupIdSet() == null)
return false;
if (other.getSecurityGroupIdSet() != null && other.getSecurityGroupIdSet().equals(this.getSecurityGroupIdSet()) == false)
return false;
if (other.getSecurityGroupSet() == null ^ this.getSecurityGroupSet() == null)
return false;
if (other.getSecurityGroupSet() != null && other.getSecurityGroupSet().equals(this.getSecurityGroupSet()) == false)
return false;
if (other.getUserData() == null ^ this.getUserData() == null)
return false;
if (other.getUserData() != null && other.getUserData().equals(this.getUserData()) == false)
return false;
return true;
}
@Override
public int hashCode() {
final int prime = 31;
int hashCode = 1;
hashCode = prime * hashCode + ((getBlockDeviceMappingSet() == null) ? 0 : getBlockDeviceMappingSet().hashCode());
hashCode = prime * hashCode + ((getCapacityReservationSpecification() == null) ? 0 : getCapacityReservationSpecification().hashCode());
hashCode = prime * hashCode + ((getCpuOptions() == null) ? 0 : getCpuOptions().hashCode());
hashCode = prime * hashCode + ((getCreditSpecification() == null) ? 0 : getCreditSpecification().hashCode());
hashCode = prime * hashCode + ((getDisableApiStop() == null) ? 0 : getDisableApiStop().hashCode());
hashCode = prime * hashCode + ((getDisableApiTermination() == null) ? 0 : getDisableApiTermination().hashCode());
hashCode = prime * hashCode + ((getEbsOptimized() == null) ? 0 : getEbsOptimized().hashCode());
hashCode = prime * hashCode + ((getElasticGpuSpecificationSet() == null) ? 0 : getElasticGpuSpecificationSet().hashCode());
hashCode = prime * hashCode + ((getElasticInferenceAcceleratorSet() == null) ? 0 : getElasticInferenceAcceleratorSet().hashCode());
hashCode = prime * hashCode + ((getEnclaveOptions() == null) ? 0 : getEnclaveOptions().hashCode());
hashCode = prime * hashCode + ((getHibernationOptions() == null) ? 0 : getHibernationOptions().hashCode());
hashCode = prime * hashCode + ((getIamInstanceProfile() == null) ? 0 : getIamInstanceProfile().hashCode());
hashCode = prime * hashCode + ((getImageId() == null) ? 0 : getImageId().hashCode());
hashCode = prime * hashCode + ((getInstanceInitiatedShutdownBehavior() == null) ? 0 : getInstanceInitiatedShutdownBehavior().hashCode());
hashCode = prime * hashCode + ((getInstanceMarketOptions() == null) ? 0 : getInstanceMarketOptions().hashCode());
hashCode = prime * hashCode + ((getInstanceRequirements() == null) ? 0 : getInstanceRequirements().hashCode());
hashCode = prime * hashCode + ((getInstanceType() == null) ? 0 : getInstanceType().hashCode());
hashCode = prime * hashCode + ((getKernelId() == null) ? 0 : getKernelId().hashCode());
hashCode = prime * hashCode + ((getKeyName() == null) ? 0 : getKeyName().hashCode());
hashCode = prime * hashCode + ((getLicenseSet() == null) ? 0 : getLicenseSet().hashCode());
hashCode = prime * hashCode + ((getMaintenanceOptions() == null) ? 0 : getMaintenanceOptions().hashCode());
hashCode = prime * hashCode + ((getMetadataOptions() == null) ? 0 : getMetadataOptions().hashCode());
hashCode = prime * hashCode + ((getMonitoring() == null) ? 0 : getMonitoring().hashCode());
hashCode = prime * hashCode + ((getNetworkInterfaceSet() == null) ? 0 : getNetworkInterfaceSet().hashCode());
hashCode = prime * hashCode + ((getPlacement() == null) ? 0 : getPlacement().hashCode());
hashCode = prime * hashCode + ((getPrivateDnsNameOptions() == null) ? 0 : getPrivateDnsNameOptions().hashCode());
hashCode = prime * hashCode + ((getRamDiskId() == null) ? 0 : getRamDiskId().hashCode());
hashCode = prime * hashCode + ((getSecurityGroupIdSet() == null) ? 0 : getSecurityGroupIdSet().hashCode());
hashCode = prime * hashCode + ((getSecurityGroupSet() == null) ? 0 : getSecurityGroupSet().hashCode());
hashCode = prime * hashCode + ((getUserData() == null) ? 0 : getUserData().hashCode());
return hashCode;
}
@Override
public AwsEc2LaunchTemplateDataDetails clone() {
try {
return (AwsEc2LaunchTemplateDataDetails) super.clone();
} catch (CloneNotSupportedException e) {
throw new IllegalStateException("Got a CloneNotSupportedException from Object.clone() " + "even though we're Cloneable!", e);
}
}
@com.amazonaws.annotation.SdkInternalApi
@Override
public void marshall(ProtocolMarshaller protocolMarshaller) {
com.amazonaws.services.securityhub.model.transform.AwsEc2LaunchTemplateDataDetailsMarshaller.getInstance().marshall(this, protocolMarshaller);
}
}