/* * 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.imagebuilder.model; import java.io.Serializable; import javax.annotation.Generated; import com.amazonaws.protocol.StructuredPojo; import com.amazonaws.protocol.ProtocolMarshaller; /** *
* Details of the infrastructure configuration. *
* * @see AWS API Documentation */ @Generated("com.amazonaws:aws-java-sdk-code-generator") public class InfrastructureConfiguration implements Serializable, Cloneable, StructuredPojo { /** ** The Amazon Resource Name (ARN) of the infrastructure configuration. *
*/ private String arn; /** ** The name of the infrastructure configuration. *
*/ private String name; /** ** The description of the infrastructure configuration. *
*/ private String description; /** ** The instance types of the infrastructure configuration. *
*/ private java.util.List* The instance profile of the infrastructure configuration. *
*/ private String instanceProfileName; /** ** The security group IDs of the infrastructure configuration. *
*/ private java.util.List* The subnet ID of the infrastructure configuration. *
*/ private String subnetId; /** ** The logging configuration of the infrastructure configuration. *
*/ private Logging logging; /** ** The Amazon EC2 key pair of the infrastructure configuration. *
*/ private String keyPair; /** ** The terminate instance on failure configuration of the infrastructure configuration. *
*/ private Boolean terminateInstanceOnFailure; /** ** The Amazon Resource Name (ARN) for the SNS topic to which we send image build event notifications. *
** EC2 Image Builder is unable to send notifications to SNS topics that are encrypted using keys from other * accounts. The key that is used to encrypt the SNS topic must reside in the account that the Image Builder service * runs under. *
** The date on which the infrastructure configuration was created. *
*/ private String dateCreated; /** ** The date on which the infrastructure configuration was last updated. *
*/ private String dateUpdated; /** ** The tags attached to the resource created by Image Builder. *
*/ private java.util.Map* The instance metadata option settings for the infrastructure configuration. *
*/ private InstanceMetadataOptions instanceMetadataOptions; /** ** The tags of the infrastructure configuration. *
*/ private java.util.Map* The Amazon Resource Name (ARN) of the infrastructure configuration. *
* * @param arn * The Amazon Resource Name (ARN) of the infrastructure configuration. */ public void setArn(String arn) { this.arn = arn; } /** ** The Amazon Resource Name (ARN) of the infrastructure configuration. *
* * @return The Amazon Resource Name (ARN) of the infrastructure configuration. */ public String getArn() { return this.arn; } /** ** The Amazon Resource Name (ARN) of the infrastructure configuration. *
* * @param arn * The Amazon Resource Name (ARN) of the infrastructure configuration. * @return Returns a reference to this object so that method calls can be chained together. */ public InfrastructureConfiguration withArn(String arn) { setArn(arn); return this; } /** ** The name of the infrastructure configuration. *
* * @param name * The name of the infrastructure configuration. */ public void setName(String name) { this.name = name; } /** ** The name of the infrastructure configuration. *
* * @return The name of the infrastructure configuration. */ public String getName() { return this.name; } /** ** The name of the infrastructure configuration. *
* * @param name * The name of the infrastructure configuration. * @return Returns a reference to this object so that method calls can be chained together. */ public InfrastructureConfiguration withName(String name) { setName(name); return this; } /** ** The description of the infrastructure configuration. *
* * @param description * The description of the infrastructure configuration. */ public void setDescription(String description) { this.description = description; } /** ** The description of the infrastructure configuration. *
* * @return The description of the infrastructure configuration. */ public String getDescription() { return this.description; } /** ** The description of the infrastructure configuration. *
* * @param description * The description of the infrastructure configuration. * @return Returns a reference to this object so that method calls can be chained together. */ public InfrastructureConfiguration withDescription(String description) { setDescription(description); return this; } /** ** The instance types of the infrastructure configuration. *
* * @return The instance types of the infrastructure configuration. */ public java.util.List* The instance types of the infrastructure configuration. *
* * @param instanceTypes * The instance types of the infrastructure configuration. */ public void setInstanceTypes(java.util.Collection* The instance types of the infrastructure configuration. *
** NOTE: This method appends the values to the existing list (if any). Use * {@link #setInstanceTypes(java.util.Collection)} or {@link #withInstanceTypes(java.util.Collection)} if you want * to override the existing values. *
* * @param instanceTypes * The instance types of the infrastructure configuration. * @return Returns a reference to this object so that method calls can be chained together. */ public InfrastructureConfiguration withInstanceTypes(String... instanceTypes) { if (this.instanceTypes == null) { setInstanceTypes(new java.util.ArrayList* The instance types of the infrastructure configuration. *
* * @param instanceTypes * The instance types of the infrastructure configuration. * @return Returns a reference to this object so that method calls can be chained together. */ public InfrastructureConfiguration withInstanceTypes(java.util.Collection* The instance profile of the infrastructure configuration. *
* * @param instanceProfileName * The instance profile of the infrastructure configuration. */ public void setInstanceProfileName(String instanceProfileName) { this.instanceProfileName = instanceProfileName; } /** ** The instance profile of the infrastructure configuration. *
* * @return The instance profile of the infrastructure configuration. */ public String getInstanceProfileName() { return this.instanceProfileName; } /** ** The instance profile of the infrastructure configuration. *
* * @param instanceProfileName * The instance profile of the infrastructure configuration. * @return Returns a reference to this object so that method calls can be chained together. */ public InfrastructureConfiguration withInstanceProfileName(String instanceProfileName) { setInstanceProfileName(instanceProfileName); return this; } /** ** The security group IDs of the infrastructure configuration. *
* * @return The security group IDs of the infrastructure configuration. */ public java.util.List* The security group IDs of the infrastructure configuration. *
* * @param securityGroupIds * The security group IDs of the infrastructure configuration. */ public void setSecurityGroupIds(java.util.Collection* The security group IDs of the infrastructure configuration. *
** NOTE: This method appends the values to the existing list (if any). Use * {@link #setSecurityGroupIds(java.util.Collection)} or {@link #withSecurityGroupIds(java.util.Collection)} if you * want to override the existing values. *
* * @param securityGroupIds * The security group IDs of the infrastructure configuration. * @return Returns a reference to this object so that method calls can be chained together. */ public InfrastructureConfiguration withSecurityGroupIds(String... securityGroupIds) { if (this.securityGroupIds == null) { setSecurityGroupIds(new java.util.ArrayList* The security group IDs of the infrastructure configuration. *
* * @param securityGroupIds * The security group IDs of the infrastructure configuration. * @return Returns a reference to this object so that method calls can be chained together. */ public InfrastructureConfiguration withSecurityGroupIds(java.util.Collection* The subnet ID of the infrastructure configuration. *
* * @param subnetId * The subnet ID of the infrastructure configuration. */ public void setSubnetId(String subnetId) { this.subnetId = subnetId; } /** ** The subnet ID of the infrastructure configuration. *
* * @return The subnet ID of the infrastructure configuration. */ public String getSubnetId() { return this.subnetId; } /** ** The subnet ID of the infrastructure configuration. *
* * @param subnetId * The subnet ID of the infrastructure configuration. * @return Returns a reference to this object so that method calls can be chained together. */ public InfrastructureConfiguration withSubnetId(String subnetId) { setSubnetId(subnetId); return this; } /** ** The logging configuration of the infrastructure configuration. *
* * @param logging * The logging configuration of the infrastructure configuration. */ public void setLogging(Logging logging) { this.logging = logging; } /** ** The logging configuration of the infrastructure configuration. *
* * @return The logging configuration of the infrastructure configuration. */ public Logging getLogging() { return this.logging; } /** ** The logging configuration of the infrastructure configuration. *
* * @param logging * The logging configuration of the infrastructure configuration. * @return Returns a reference to this object so that method calls can be chained together. */ public InfrastructureConfiguration withLogging(Logging logging) { setLogging(logging); return this; } /** ** The Amazon EC2 key pair of the infrastructure configuration. *
* * @param keyPair * The Amazon EC2 key pair of the infrastructure configuration. */ public void setKeyPair(String keyPair) { this.keyPair = keyPair; } /** ** The Amazon EC2 key pair of the infrastructure configuration. *
* * @return The Amazon EC2 key pair of the infrastructure configuration. */ public String getKeyPair() { return this.keyPair; } /** ** The Amazon EC2 key pair of the infrastructure configuration. *
* * @param keyPair * The Amazon EC2 key pair of the infrastructure configuration. * @return Returns a reference to this object so that method calls can be chained together. */ public InfrastructureConfiguration withKeyPair(String keyPair) { setKeyPair(keyPair); return this; } /** ** The terminate instance on failure configuration of the infrastructure configuration. *
* * @param terminateInstanceOnFailure * The terminate instance on failure configuration of the infrastructure configuration. */ public void setTerminateInstanceOnFailure(Boolean terminateInstanceOnFailure) { this.terminateInstanceOnFailure = terminateInstanceOnFailure; } /** ** The terminate instance on failure configuration of the infrastructure configuration. *
* * @return The terminate instance on failure configuration of the infrastructure configuration. */ public Boolean getTerminateInstanceOnFailure() { return this.terminateInstanceOnFailure; } /** ** The terminate instance on failure configuration of the infrastructure configuration. *
* * @param terminateInstanceOnFailure * The terminate instance on failure configuration of the infrastructure configuration. * @return Returns a reference to this object so that method calls can be chained together. */ public InfrastructureConfiguration withTerminateInstanceOnFailure(Boolean terminateInstanceOnFailure) { setTerminateInstanceOnFailure(terminateInstanceOnFailure); return this; } /** ** The terminate instance on failure configuration of the infrastructure configuration. *
* * @return The terminate instance on failure configuration of the infrastructure configuration. */ public Boolean isTerminateInstanceOnFailure() { return this.terminateInstanceOnFailure; } /** ** The Amazon Resource Name (ARN) for the SNS topic to which we send image build event notifications. *
** EC2 Image Builder is unable to send notifications to SNS topics that are encrypted using keys from other * accounts. The key that is used to encrypt the SNS topic must reside in the account that the Image Builder service * runs under. *
** EC2 Image Builder is unable to send notifications to SNS topics that are encrypted using keys from other * accounts. The key that is used to encrypt the SNS topic must reside in the account that the Image Builder * service runs under. *
*/ public void setSnsTopicArn(String snsTopicArn) { this.snsTopicArn = snsTopicArn; } /** ** The Amazon Resource Name (ARN) for the SNS topic to which we send image build event notifications. *
** EC2 Image Builder is unable to send notifications to SNS topics that are encrypted using keys from other * accounts. The key that is used to encrypt the SNS topic must reside in the account that the Image Builder service * runs under. *
** EC2 Image Builder is unable to send notifications to SNS topics that are encrypted using keys from other * accounts. The key that is used to encrypt the SNS topic must reside in the account that the Image Builder * service runs under. *
*/ public String getSnsTopicArn() { return this.snsTopicArn; } /** ** The Amazon Resource Name (ARN) for the SNS topic to which we send image build event notifications. *
** EC2 Image Builder is unable to send notifications to SNS topics that are encrypted using keys from other * accounts. The key that is used to encrypt the SNS topic must reside in the account that the Image Builder service * runs under. *
** EC2 Image Builder is unable to send notifications to SNS topics that are encrypted using keys from other * accounts. The key that is used to encrypt the SNS topic must reside in the account that the Image Builder * service runs under. *
* @return Returns a reference to this object so that method calls can be chained together. */ public InfrastructureConfiguration withSnsTopicArn(String snsTopicArn) { setSnsTopicArn(snsTopicArn); return this; } /** ** The date on which the infrastructure configuration was created. *
* * @param dateCreated * The date on which the infrastructure configuration was created. */ public void setDateCreated(String dateCreated) { this.dateCreated = dateCreated; } /** ** The date on which the infrastructure configuration was created. *
* * @return The date on which the infrastructure configuration was created. */ public String getDateCreated() { return this.dateCreated; } /** ** The date on which the infrastructure configuration was created. *
* * @param dateCreated * The date on which the infrastructure configuration was created. * @return Returns a reference to this object so that method calls can be chained together. */ public InfrastructureConfiguration withDateCreated(String dateCreated) { setDateCreated(dateCreated); return this; } /** ** The date on which the infrastructure configuration was last updated. *
* * @param dateUpdated * The date on which the infrastructure configuration was last updated. */ public void setDateUpdated(String dateUpdated) { this.dateUpdated = dateUpdated; } /** ** The date on which the infrastructure configuration was last updated. *
* * @return The date on which the infrastructure configuration was last updated. */ public String getDateUpdated() { return this.dateUpdated; } /** ** The date on which the infrastructure configuration was last updated. *
* * @param dateUpdated * The date on which the infrastructure configuration was last updated. * @return Returns a reference to this object so that method calls can be chained together. */ public InfrastructureConfiguration withDateUpdated(String dateUpdated) { setDateUpdated(dateUpdated); return this; } /** ** The tags attached to the resource created by Image Builder. *
* * @return The tags attached to the resource created by Image Builder. */ public java.util.Map* The tags attached to the resource created by Image Builder. *
* * @param resourceTags * The tags attached to the resource created by Image Builder. */ public void setResourceTags(java.util.Map* The tags attached to the resource created by Image Builder. *
* * @param resourceTags * The tags attached to the resource created by Image Builder. * @return Returns a reference to this object so that method calls can be chained together. */ public InfrastructureConfiguration withResourceTags(java.util.Map* The instance metadata option settings for the infrastructure configuration. *
* * @param instanceMetadataOptions * The instance metadata option settings for the infrastructure configuration. */ public void setInstanceMetadataOptions(InstanceMetadataOptions instanceMetadataOptions) { this.instanceMetadataOptions = instanceMetadataOptions; } /** ** The instance metadata option settings for the infrastructure configuration. *
* * @return The instance metadata option settings for the infrastructure configuration. */ public InstanceMetadataOptions getInstanceMetadataOptions() { return this.instanceMetadataOptions; } /** ** The instance metadata option settings for the infrastructure configuration. *
* * @param instanceMetadataOptions * The instance metadata option settings for the infrastructure configuration. * @return Returns a reference to this object so that method calls can be chained together. */ public InfrastructureConfiguration withInstanceMetadataOptions(InstanceMetadataOptions instanceMetadataOptions) { setInstanceMetadataOptions(instanceMetadataOptions); return this; } /** ** The tags of the infrastructure configuration. *
* * @return The tags of the infrastructure configuration. */ public java.util.Map* The tags of the infrastructure configuration. *
* * @param tags * The tags of the infrastructure configuration. */ public void setTags(java.util.Map* The tags of the infrastructure configuration. *
* * @param tags * The tags of the infrastructure configuration. * @return Returns a reference to this object so that method calls can be chained together. */ public InfrastructureConfiguration withTags(java.util.Map