/*
* 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.ec2.model;
import java.io.Serializable;
import javax.annotation.Generated;
import com.amazonaws.AmazonWebServiceRequest;
import com.amazonaws.Request;
import com.amazonaws.services.ec2.model.transform.CreateInstanceConnectEndpointRequestMarshaller;
/**
*
*/
@Generated("com.amazonaws:aws-java-sdk-code-generator")
public class CreateInstanceConnectEndpointRequest extends AmazonWebServiceRequest implements Serializable, Cloneable,
DryRunSupportedRequest
* The ID of the subnet in which to create the EC2 Instance Connect Endpoint.
*
* One or more security groups to associate with the endpoint. If you don't specify a security group, the default
* security group for your VPC will be associated with the endpoint.
*
* Indicates whether your client's IP address is preserved as the source. The value is
* If
* If
* Default:
* Unique, case-sensitive identifier that you provide to ensure the idempotency of the request.
*
* The tags to apply to the EC2 Instance Connect Endpoint during creation.
*
* The ID of the subnet in which to create the EC2 Instance Connect Endpoint.
*
* The ID of the subnet in which to create the EC2 Instance Connect Endpoint.
*
* The ID of the subnet in which to create the EC2 Instance Connect Endpoint.
*
* One or more security groups to associate with the endpoint. If you don't specify a security group, the default
* security group for your VPC will be associated with the endpoint.
*
* One or more security groups to associate with the endpoint. If you don't specify a security group, the default
* security group for your VPC will be associated with the endpoint.
*
* One or more security groups to associate with the endpoint. If you don't specify a security group, the default
* security group for your VPC will be associated with the endpoint.
*
* 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.
*
* One or more security groups to associate with the endpoint. If you don't specify a security group, the default
* security group for your VPC will be associated with the endpoint.
*
* Indicates whether your client's IP address is preserved as the source. The value is
* If
* If
* Default: true
or
* false
.
*
*
* true
, your client's IP address is used when you connect to a resource.
* false
, the elastic network interface IP address is used when you connect to a resource.
* true
* true
or
* false
.
*
*
* true
, your client's IP address is used when you connect to a resource.
* false
, the elastic network interface IP address is used when you connect to a resource.
* true
* true
or
* false
.
* If true
, your client's IP address is used when you connect to a resource.
*
* If false
, the elastic network interface IP address is used when you connect to a resource.
*
* Default: true
*/
public void setPreserveClientIp(Boolean preserveClientIp) {
this.preserveClientIp = preserveClientIp;
}
/**
*
* Indicates whether your client's IP address is preserved as the source. The value is true
or
* false
.
*
* If true
, your client's IP address is used when you connect to a resource.
*
* If false
, the elastic network interface IP address is used when you connect to a resource.
*
* Default: true
*
true
or
* false
.
*
* If true
, your client's IP address is used when you connect to a resource.
*
* If false
, the elastic network interface IP address is used when you connect to a resource.
*
* Default: true
*/
public Boolean getPreserveClientIp() {
return this.preserveClientIp;
}
/**
*
* Indicates whether your client's IP address is preserved as the source. The value is true
or
* false
.
*
* If true
, your client's IP address is used when you connect to a resource.
*
* If false
, the elastic network interface IP address is used when you connect to a resource.
*
* Default: true
*
true
or
* false
.
*
* If true
, your client's IP address is used when you connect to a resource.
*
* If false
, the elastic network interface IP address is used when you connect to a resource.
*
* Default: true
* @return Returns a reference to this object so that method calls can be chained together.
*/
public CreateInstanceConnectEndpointRequest withPreserveClientIp(Boolean preserveClientIp) {
setPreserveClientIp(preserveClientIp);
return this;
}
/**
*
* Indicates whether your client's IP address is preserved as the source. The value is true
or
* false
.
*
* If true
, your client's IP address is used when you connect to a resource.
*
* If false
, the elastic network interface IP address is used when you connect to a resource.
*
* Default: true
*
true
or
* false
.
*
* If true
, your client's IP address is used when you connect to a resource.
*
* If false
, the elastic network interface IP address is used when you connect to a resource.
*
* Default: true
*/
public Boolean isPreserveClientIp() {
return this.preserveClientIp;
}
/**
*
* Unique, case-sensitive identifier that you provide to ensure the idempotency of the request. *
* * @param clientToken * Unique, case-sensitive identifier that you provide to ensure the idempotency of the request. */ public void setClientToken(String clientToken) { this.clientToken = clientToken; } /** ** Unique, case-sensitive identifier that you provide to ensure the idempotency of the request. *
* * @return Unique, case-sensitive identifier that you provide to ensure the idempotency of the request. */ public String getClientToken() { return this.clientToken; } /** ** Unique, case-sensitive identifier that you provide to ensure the idempotency of the request. *
* * @param clientToken * Unique, case-sensitive identifier that you provide to ensure the idempotency of the request. * @return Returns a reference to this object so that method calls can be chained together. */ public CreateInstanceConnectEndpointRequest withClientToken(String clientToken) { setClientToken(clientToken); return this; } /** ** The tags to apply to the EC2 Instance Connect Endpoint during creation. *
* * @return The tags to apply to the EC2 Instance Connect Endpoint during creation. */ public java.util.List* The tags to apply to the EC2 Instance Connect Endpoint during creation. *
* * @param tagSpecifications * The tags to apply to the EC2 Instance Connect Endpoint during creation. */ public void setTagSpecifications(java.util.Collection* The tags to apply to the EC2 Instance Connect Endpoint during creation. *
** NOTE: This method appends the values to the existing list (if any). Use * {@link #setTagSpecifications(java.util.Collection)} or {@link #withTagSpecifications(java.util.Collection)} if * you want to override the existing values. *
* * @param tagSpecifications * The tags to apply to the EC2 Instance Connect Endpoint during creation. * @return Returns a reference to this object so that method calls can be chained together. */ public CreateInstanceConnectEndpointRequest withTagSpecifications(TagSpecification... tagSpecifications) { if (this.tagSpecifications == null) { setTagSpecifications(new com.amazonaws.internal.SdkInternalList* The tags to apply to the EC2 Instance Connect Endpoint during creation. *
* * @param tagSpecifications * The tags to apply to the EC2 Instance Connect Endpoint during creation. * @return Returns a reference to this object so that method calls can be chained together. */ public CreateInstanceConnectEndpointRequest withTagSpecifications(java.util.Collection