/* * 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.shield.model; import java.io.Serializable; import javax.annotation.Generated; import com.amazonaws.AmazonWebServiceRequest; /** * * @see AWS API * Documentation */ @Generated("com.amazonaws:aws-java-sdk-code-generator") public class CreateProtectionRequest extends com.amazonaws.AmazonWebServiceRequest implements Serializable, Cloneable { /** *
* Friendly name for the Protection
you are creating.
*
* The ARN (Amazon Resource Name) of the resource to be protected. *
** The ARN should be in one of the following formats: *
*
* For an Application Load Balancer:
* arn:aws:elasticloadbalancing:region:account-id:loadbalancer/app/load-balancer-name/load-balancer-id
*
* For an Elastic Load Balancer (Classic Load Balancer):
* arn:aws:elasticloadbalancing:region:account-id:loadbalancer/load-balancer-name
*
* For an Amazon CloudFront distribution:
* arn:aws:cloudfront::account-id:distribution/distribution-id
*
* For an Global Accelerator standard accelerator:
* arn:aws:globalaccelerator::account-id:accelerator/accelerator-id
*
* For Amazon Route 53: arn:aws:route53:::hostedzone/hosted-zone-id
*
* For an Elastic IP address:
* arn:aws:ec2:region:account-id:eip-allocation/allocation-id
*
* One or more tag key-value pairs for the Protection object that is created. *
*/ private java.util.List
* Friendly name for the Protection
you are creating.
*
Protection
you are creating.
*/
public void setName(String name) {
this.name = name;
}
/**
*
* Friendly name for the Protection
you are creating.
*
Protection
you are creating.
*/
public String getName() {
return this.name;
}
/**
*
* Friendly name for the Protection
you are creating.
*
Protection
you are creating.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public CreateProtectionRequest withName(String name) {
setName(name);
return this;
}
/**
* * The ARN (Amazon Resource Name) of the resource to be protected. *
** The ARN should be in one of the following formats: *
*
* For an Application Load Balancer:
* arn:aws:elasticloadbalancing:region:account-id:loadbalancer/app/load-balancer-name/load-balancer-id
*
* For an Elastic Load Balancer (Classic Load Balancer):
* arn:aws:elasticloadbalancing:region:account-id:loadbalancer/load-balancer-name
*
* For an Amazon CloudFront distribution:
* arn:aws:cloudfront::account-id:distribution/distribution-id
*
* For an Global Accelerator standard accelerator:
* arn:aws:globalaccelerator::account-id:accelerator/accelerator-id
*
* For Amazon Route 53: arn:aws:route53:::hostedzone/hosted-zone-id
*
* For an Elastic IP address:
* arn:aws:ec2:region:account-id:eip-allocation/allocation-id
*
* The ARN should be in one of the following formats: *
*
* For an Application Load Balancer:
* arn:aws:elasticloadbalancing:region:account-id:loadbalancer/app/load-balancer-name/load-balancer-id
*
* For an Elastic Load Balancer (Classic Load Balancer):
* arn:aws:elasticloadbalancing:region:account-id:loadbalancer/load-balancer-name
*
* For an Amazon CloudFront distribution:
* arn:aws:cloudfront::account-id:distribution/distribution-id
*
* For an Global Accelerator standard accelerator:
* arn:aws:globalaccelerator::account-id:accelerator/accelerator-id
*
* For Amazon Route 53: arn:aws:route53:::hostedzone/hosted-zone-id
*
* For an Elastic IP address:
* arn:aws:ec2:region:account-id:eip-allocation/allocation-id
*
* The ARN (Amazon Resource Name) of the resource to be protected. *
** The ARN should be in one of the following formats: *
*
* For an Application Load Balancer:
* arn:aws:elasticloadbalancing:region:account-id:loadbalancer/app/load-balancer-name/load-balancer-id
*
* For an Elastic Load Balancer (Classic Load Balancer):
* arn:aws:elasticloadbalancing:region:account-id:loadbalancer/load-balancer-name
*
* For an Amazon CloudFront distribution:
* arn:aws:cloudfront::account-id:distribution/distribution-id
*
* For an Global Accelerator standard accelerator:
* arn:aws:globalaccelerator::account-id:accelerator/accelerator-id
*
* For Amazon Route 53: arn:aws:route53:::hostedzone/hosted-zone-id
*
* For an Elastic IP address:
* arn:aws:ec2:region:account-id:eip-allocation/allocation-id
*
* The ARN should be in one of the following formats: *
*
* For an Application Load Balancer:
* arn:aws:elasticloadbalancing:region:account-id:loadbalancer/app/load-balancer-name/load-balancer-id
*
* For an Elastic Load Balancer (Classic Load Balancer):
* arn:aws:elasticloadbalancing:region:account-id:loadbalancer/load-balancer-name
*
* For an Amazon CloudFront distribution:
* arn:aws:cloudfront::account-id:distribution/distribution-id
*
* For an Global Accelerator standard accelerator:
* arn:aws:globalaccelerator::account-id:accelerator/accelerator-id
*
* For Amazon Route 53: arn:aws:route53:::hostedzone/hosted-zone-id
*
* For an Elastic IP address:
* arn:aws:ec2:region:account-id:eip-allocation/allocation-id
*
* The ARN (Amazon Resource Name) of the resource to be protected. *
** The ARN should be in one of the following formats: *
*
* For an Application Load Balancer:
* arn:aws:elasticloadbalancing:region:account-id:loadbalancer/app/load-balancer-name/load-balancer-id
*
* For an Elastic Load Balancer (Classic Load Balancer):
* arn:aws:elasticloadbalancing:region:account-id:loadbalancer/load-balancer-name
*
* For an Amazon CloudFront distribution:
* arn:aws:cloudfront::account-id:distribution/distribution-id
*
* For an Global Accelerator standard accelerator:
* arn:aws:globalaccelerator::account-id:accelerator/accelerator-id
*
* For Amazon Route 53: arn:aws:route53:::hostedzone/hosted-zone-id
*
* For an Elastic IP address:
* arn:aws:ec2:region:account-id:eip-allocation/allocation-id
*
* The ARN should be in one of the following formats: *
*
* For an Application Load Balancer:
* arn:aws:elasticloadbalancing:region:account-id:loadbalancer/app/load-balancer-name/load-balancer-id
*
* For an Elastic Load Balancer (Classic Load Balancer):
* arn:aws:elasticloadbalancing:region:account-id:loadbalancer/load-balancer-name
*
* For an Amazon CloudFront distribution:
* arn:aws:cloudfront::account-id:distribution/distribution-id
*
* For an Global Accelerator standard accelerator:
* arn:aws:globalaccelerator::account-id:accelerator/accelerator-id
*
* For Amazon Route 53: arn:aws:route53:::hostedzone/hosted-zone-id
*
* For an Elastic IP address:
* arn:aws:ec2:region:account-id:eip-allocation/allocation-id
*
* One or more tag key-value pairs for the Protection object that is created. *
* * @return One or more tag key-value pairs for the Protection object that is created. */ public java.util.List* One or more tag key-value pairs for the Protection object that is created. *
* * @param tags * One or more tag key-value pairs for the Protection object that is created. */ public void setTags(java.util.Collection* One or more tag key-value pairs for the Protection object that is created. *
** NOTE: This method appends the values to the existing list (if any). Use * {@link #setTags(java.util.Collection)} or {@link #withTags(java.util.Collection)} if you want to override the * existing values. *
* * @param tags * One or more tag key-value pairs for the Protection object that is created. * @return Returns a reference to this object so that method calls can be chained together. */ public CreateProtectionRequest withTags(Tag... tags) { if (this.tags == null) { setTags(new java.util.ArrayList* One or more tag key-value pairs for the Protection object that is created. *
* * @param tags * One or more tag key-value pairs for the Protection object that is created. * @return Returns a reference to this object so that method calls can be chained together. */ public CreateProtectionRequest withTags(java.util.Collection