/* * 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.rds.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 CreateDBSecurityGroupRequest extends com.amazonaws.AmazonWebServiceRequest implements Serializable, Cloneable { /** ** The name for the DB security group. This value is stored as a lowercase string. *
** Constraints: *
** Must be 1 to 255 letters, numbers, or hyphens. *
** First character must be a letter *
** Can't end with a hyphen or contain two consecutive hyphens *
** Must not be "Default" *
*
* Example: mysecuritygroup
*
* The description for the DB security group. *
*/ private String dBSecurityGroupDescription; /** ** Tags to assign to the DB security group. *
*/ private com.amazonaws.internal.SdkInternalList* Constraints: *
** Must be 1 to 255 letters, numbers, or hyphens. *
** First character must be a letter *
** Can't end with a hyphen or contain two consecutive hyphens *
** Must not be "Default" *
*
* Example: mysecuritygroup
* @param dBSecurityGroupDescription
* The description for the DB security group.
*/
public CreateDBSecurityGroupRequest(String dBSecurityGroupName, String dBSecurityGroupDescription) {
setDBSecurityGroupName(dBSecurityGroupName);
setDBSecurityGroupDescription(dBSecurityGroupDescription);
}
/**
*
* The name for the DB security group. This value is stored as a lowercase string. *
** Constraints: *
** Must be 1 to 255 letters, numbers, or hyphens. *
** First character must be a letter *
** Can't end with a hyphen or contain two consecutive hyphens *
** Must not be "Default" *
*
* Example: mysecuritygroup
*
* Constraints: *
** Must be 1 to 255 letters, numbers, or hyphens. *
** First character must be a letter *
** Can't end with a hyphen or contain two consecutive hyphens *
** Must not be "Default" *
*
* Example: mysecuritygroup
*/
public void setDBSecurityGroupName(String dBSecurityGroupName) {
this.dBSecurityGroupName = dBSecurityGroupName;
}
/**
*
* The name for the DB security group. This value is stored as a lowercase string. *
** Constraints: *
** Must be 1 to 255 letters, numbers, or hyphens. *
** First character must be a letter *
** Can't end with a hyphen or contain two consecutive hyphens *
** Must not be "Default" *
*
* Example: mysecuritygroup
*
* Constraints: *
** Must be 1 to 255 letters, numbers, or hyphens. *
** First character must be a letter *
** Can't end with a hyphen or contain two consecutive hyphens *
** Must not be "Default" *
*
* Example: mysecuritygroup
*/
public String getDBSecurityGroupName() {
return this.dBSecurityGroupName;
}
/**
*
* The name for the DB security group. This value is stored as a lowercase string. *
** Constraints: *
** Must be 1 to 255 letters, numbers, or hyphens. *
** First character must be a letter *
** Can't end with a hyphen or contain two consecutive hyphens *
** Must not be "Default" *
*
* Example: mysecuritygroup
*
* Constraints: *
** Must be 1 to 255 letters, numbers, or hyphens. *
** First character must be a letter *
** Can't end with a hyphen or contain two consecutive hyphens *
** Must not be "Default" *
*
* Example: mysecuritygroup
* @return Returns a reference to this object so that method calls can be chained together.
*/
public CreateDBSecurityGroupRequest withDBSecurityGroupName(String dBSecurityGroupName) {
setDBSecurityGroupName(dBSecurityGroupName);
return this;
}
/**
*
* The description for the DB security group. *
* * @param dBSecurityGroupDescription * The description for the DB security group. */ public void setDBSecurityGroupDescription(String dBSecurityGroupDescription) { this.dBSecurityGroupDescription = dBSecurityGroupDescription; } /** ** The description for the DB security group. *
* * @return The description for the DB security group. */ public String getDBSecurityGroupDescription() { return this.dBSecurityGroupDescription; } /** ** The description for the DB security group. *
* * @param dBSecurityGroupDescription * The description for the DB security group. * @return Returns a reference to this object so that method calls can be chained together. */ public CreateDBSecurityGroupRequest withDBSecurityGroupDescription(String dBSecurityGroupDescription) { setDBSecurityGroupDescription(dBSecurityGroupDescription); return this; } /** ** Tags to assign to the DB security group. *
* * @return Tags to assign to the DB security group. */ public java.util.List* Tags to assign to the DB security group. *
* * @param tags * Tags to assign to the DB security group. */ public void setTags(java.util.Collection* Tags to assign to the DB security group. *
** 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 * Tags to assign to the DB security group. * @return Returns a reference to this object so that method calls can be chained together. */ public CreateDBSecurityGroupRequest withTags(Tag... tags) { if (this.tags == null) { setTags(new com.amazonaws.internal.SdkInternalList* Tags to assign to the DB security group. *
* * @param tags * Tags to assign to the DB security group. * @return Returns a reference to this object so that method calls can be chained together. */ public CreateDBSecurityGroupRequest withTags(java.util.Collection