text:
package com.amazonaws.services.neptune.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 RestoreDBClusterFromSnapshotRequest extends com.amazonaws.AmazonWebServiceRequest implements Serializable, Cloneable {

    /**
     *

     * Provides the list of EC2 Availability Zones that instances in the restored DB cluster can be created in.
     *

     */
    private java.util.List<String> availabilityZones;
    /**
     *

     * The name of the DB cluster to create from the DB snapshot or DB cluster snapshot. This parameter isn't
     * case-sensitive.
     *

     *

     * Constraints:
     *

     *

     *

     *

     * Must contain from 1 to 63 letters, numbers, or hyphens
     *

     *

     *

     *

     * First character must be a letter
     *

     *

     *

     *

     * Cannot end with a hyphen or contain two consecutive hyphens
     *

     *

     *

     *

     * Example: my-snapshot-id
     *

     */
    private String dBClusterIdentifier;
    /**
     *

     * The identifier for the DB snapshot or DB cluster snapshot to restore from.
     *

     *

     * You can use either the name or the Amazon Resource Name (ARN) to specify a DB cluster snapshot. However, you can
     * use only the ARN to specify a DB snapshot.
     *

     *

     * Constraints:
     *

     *

     *

     *

     * Must match the identifier of an existing Snapshot.
     *

     *

     *

     */
    private String snapshotIdentifier;
    /**
     *

     * The database engine to use for the new DB cluster.
     *

     *

     * Default: The same as source
     *

     *

     * Constraint: Must be compatible with the engine of the source
     *

     */
    private String engine;
    /**
     *

     * The version of the database engine to use for the new DB cluster.
     *

     */
    private String engineVersion;
    /**
     *

     * The port number on which the new DB cluster accepts connections.
     *

     *

     * Constraints: Value must be 1150-65535
     *

     *

     * Default: The same port as the original DB cluster.
     *

     */
    private Integer port;
    /**
     *

     * The name of the DB subnet group to use for the new DB cluster.
     *

     *

     * Constraints: If supplied, must match the name of an existing DBSubnetGroup.
     *

     *

     * Example: mySubnetgroup
     *

     */
    private String dBSubnetGroupName;
    /**
     *

     * Not supported.
     *

     */
    private String databaseName;
    /**
     *

     * (Not supported by Neptune)
     *

     */
    private String optionGroupName;
    /**
     *

     * A list of VPC security groups that the new DB cluster will belong to.
     *

     */
    private java.util.List<String> vpcSecurityGroupIds;
    /**
     *

     * The tags to be assigned to the restored DB cluster.
     *

     */
    private java.util.List<Tag> tags;
    /**
     *

     * The Amazon KMS key identifier to use when restoring an encrypted DB cluster from a DB snapshot or DB cluster
     * snapshot.
     *

     *

     * The KMS key identifier is the Amazon Resource Name (ARN) for the KMS encryption key. If you are restoring a DB
     * cluster with the same Amazon account that owns the KMS encryption key used to encrypt the new DB cluster, then
     * you can use the KMS key alias instead of the ARN for the KMS encryption key.
     *

     *

     * If you do not specify a value for the KmsKeyId parameter, then the following will occur:
     *

     *

     *

     *

     * If the DB snapshot or DB cluster snapshot in SnapshotIdentifier is encrypted, then the restored DB
     * cluster is encrypted using the KMS key that was used to encrypt the DB snapshot or DB cluster snapshot.
     *

     *

     *

     *

     * If the DB snapshot or DB cluster snapshot in SnapshotIdentifier is not encrypted, then the restored
     * DB cluster is not encrypted.
     *

     *

     *

     */
    private String kmsKeyId;
    /**
     *

     * True to enable mapping of Amazon Identity and Access Management (IAM) accounts to database accounts, and
     * otherwise false.
     *

     *

     * Default: false
     *

     */
    private Boolean enableIAMDatabaseAuthentication;
    /**
     *

     * The list of logs that the restored DB cluster is to export to Amazon CloudWatch Logs.
     *

     */
    private java.util.List<String> enableCloudwatchLogsExports;
    /**
     *

     * The name of the DB cluster parameter group to associate with the new DB cluster.
     *

     *

     * Constraints:
     *

     *

     *

     *

     * If supplied, must match the name of an existing DBClusterParameterGroup.
     *

     *

     *

     */
    private String dBClusterParameterGroupName;
    /**
     *

     * A value that indicates whether the DB cluster has deletion protection enabled. The database can't be deleted when
     * deletion protection is enabled. By default, deletion protection is disabled.
     *

     */
    private Boolean deletionProtection;
    /**
     *

     * If set to true, tags are copied to any snapshot of the restored DB cluster that is created.
     *

     */
    private Boolean copyTagsToSnapshot;

    private ServerlessV2ScalingConfiguration serverlessV2ScalingConfiguration;

    /**
     *

     * Provides the list of EC2 Availability Zones that instances in the restored DB cluster can be created in.
     *

     *
     * @return Provides the list of EC2 Availability Zones that instances in the restored DB cluster can be created in.
     */

    public java.util.List<String> getAvailabilityZones() {
        return availabilityZones;
    }

    /**
     *

     * Provides the list of EC2 Availability Zones that instances in the restored DB cluster can be created in.
     *

     *
     * @param availabilityZones
     *        Provides the list of EC2 Availability Zones that instances in the restored DB cluster can be created in.
     */

    public void setAvailabilityZones(java.util.Collection<String> availabilityZones) {
        if (availabilityZones == null) {
            this.availabilityZones = null;
            return;
        }

        this.availabilityZones = new java.util.ArrayList<String>(availabilityZones);
    }

    /**
     *

     * Provides the list of EC2 Availability Zones that instances in the restored DB cluster can be created in.
     *

     *

     * NOTE: This method appends the values to the existing list (if any). Use
     * {@link #setAvailabilityZones(java.util.Collection)} or {@link #withAvailabilityZones(java.util.Collection)} if
     * you want to override the existing values.
     *

     *
     * @param availabilityZones
     *        Provides the list of EC2 Availability Zones that instances in the restored DB cluster can be created in.
     * @return Returns a reference to this object so that method calls can be chained together.
     */

    public RestoreDBClusterFromSnapshotRequest withAvailabilityZones(String... availabilityZones) {
        if (this.availabilityZones == null) {
            setAvailabilityZones(new java.util.ArrayList<String>(availabilityZones.length));
        }
        for (String ele : availabilityZones) {
            this.availabilityZones.add(ele);
        }
        return this;
    }

    /**
     *

     * Provides the list of EC2 Availability Zones that instances in the restored DB cluster can be created in.
     *

     *
     * @param availabilityZones
     *        Provides the list of EC2 Availability Zones that instances in the restored DB cluster can be created in.
     * @return Returns a reference to this object so that method calls can be chained together.
     */

    public RestoreDBClusterFromSnapshotRequest withAvailabilityZones(java.util.Collection<String> availabilityZones) {
        setAvailabilityZones(availabilityZones);
        return this;
    }

    /**
     *

     * The name of the DB cluster to create from the DB snapshot or DB cluster snapshot. This parameter isn't
     * case-sensitive.
     *

     *

     * Constraints:
     *

     *

     *

     *

     * Must contain from 1 to 63 letters, numbers, or hyphens
     *

     *

     *

     *

     * First character must be a letter
     *

     *

     *

     *

     * Cannot end with a hyphen or contain two consecutive hyphens
     *

     *

     *

     *

     * Example: my-snapshot-id
     *

     *
     * @param dBClusterIdentifier
     *        The name of the DB cluster to create from the DB snapshot or DB cluster snapshot. This parameter isn't
     *        case-sensitive.

     *

     *        Constraints:
     *

     *

     *

     *

     *        Must contain from 1 to 63 letters, numbers, or hyphens
     *

     *

     *

     *

     *        First character must be a letter
     *

     *

     *

     *

     *        Cannot end with a hyphen or contain two consecutive hyphens
     *

     *

     *

     *

     *        Example: my-snapshot-id
     */

    public void setDBClusterIdentifier(String dBClusterIdentifier) {
        this.dBClusterIdentifier = dBClusterIdentifier;
    }

    /**
     *

     * The name of the DB cluster to create from the DB snapshot or DB cluster snapshot. This parameter isn't
     * case-sensitive.
     *

     *

     * Constraints:
     *

     *

     *

     *

     * Must contain from 1 to 63 letters, numbers, or hyphens
     *

     *

     *

     *

     * First character must be a letter
     *

     *

     *

     *

     * Cannot end with a hyphen or contain two consecutive hyphens
     *

     *

     *

     *

     * Example: my-snapshot-id
     *

     *
     * @return The name of the DB cluster to create from the DB snapshot or DB cluster snapshot. This parameter isn't
     *         case-sensitive.

     *

     *         Constraints:
     *

     *

     *

     *

     *         Must contain from 1 to 63 letters, numbers, or hyphens
     *

     *

     *

     *

     *         First character must be a letter
     *

     *

     *

     *

     *         Cannot end with a hyphen or contain two consecutive hyphens
     *

     *

     *

     *

     *         Example: my-snapshot-id
     */

    public String getDBClusterIdentifier() {
        return this.dBClusterIdentifier;
    }

    /**
     *

     * The name of the DB cluster to create from the DB snapshot or DB cluster snapshot. This parameter isn't
     * case-sensitive.
     *

     *

     * Constraints:
     *

     *

     *

     *

     * Must contain from 1 to 63 letters, numbers, or hyphens
     *

     *

     *

     *

     * First character must be a letter
     *

     *

     *

     *

     * Cannot end with a hyphen or contain two consecutive hyphens
     *

     *

     *

     *

     * Example: my-snapshot-id
     *

     *
     * @param dBClusterIdentifier
     *        The name of the DB cluster to create from the DB snapshot or DB cluster snapshot. This parameter isn't
     *        case-sensitive.

     *

     *        Constraints:
     *

     *

     *

     *

     *        Must contain from 1 to 63 letters, numbers, or hyphens
     *

     *

     *

     *

     *        First character must be a letter
     *

     *

     *

     *

     *        Cannot end with a hyphen or contain two consecutive hyphens
     *

     *

     *

     *

     *        Example: my-snapshot-id
     * @return Returns a reference to this object so that method calls can be chained together.
     */

    public RestoreDBClusterFromSnapshotRequest withDBClusterIdentifier(String dBClusterIdentifier) {
        setDBClusterIdentifier(dBClusterIdentifier);
        return this;
    }

    /**
     *

     * The identifier for the DB snapshot or DB cluster snapshot to restore from.
     *

     *

     * You can use either the name or the Amazon Resource Name (ARN) to specify a DB cluster snapshot. However, you can
     * use only the ARN to specify a DB snapshot.
     *

     *

     * Constraints:
     *

     *

     *

     *

     * Must match the identifier of an existing Snapshot.
     *

     *

     *

     *
     * @param snapshotIdentifier
     *        The identifier for the DB snapshot or DB cluster snapshot to restore from.

     *

     *        You can use either the name or the Amazon Resource Name (ARN) to specify a DB cluster snapshot. However,
     *        you can use only the ARN to specify a DB snapshot.
     *

     *

     *        Constraints:
     *

     *

     *

     *

     *        Must match the identifier of an existing Snapshot.
     *

     *

     */

    public void setSnapshotIdentifier(String snapshotIdentifier) {
        this.snapshotIdentifier = snapshotIdentifier;
    }

    /**
     *

     * The identifier for the DB snapshot or DB cluster snapshot to restore from.
     *

     *

     * You can use either the name or the Amazon Resource Name (ARN) to specify a DB cluster snapshot. However, you can
     * use only the ARN to specify a DB snapshot.
     *

     *

     * Constraints:
     *

     *

     *

     *

     * Must match the identifier of an existing Snapshot.
     *

     *

     *

     *
     * @return The identifier for the DB snapshot or DB cluster snapshot to restore from.

     *

     *         You can use either the name or the Amazon Resource Name (ARN) to specify a DB cluster snapshot. However,
     *         you can use only the ARN to specify a DB snapshot.
     *

     *

     *         Constraints:
     *

     *

     *

     *

     *         Must match the identifier of an existing Snapshot.
     *

     *

     */

    public String getSnapshotIdentifier() {
        return this.snapshotIdentifier;
    }

    /**
     *

     * The identifier for the DB snapshot or DB cluster snapshot to restore from.
     *

     *

     * You can use either the name or the Amazon Resource Name (ARN) to specify a DB cluster snapshot. However, you can
     * use only the ARN to specify a DB snapshot.
     *

     *

     * Constraints:
     *

     *

     *

     *

     * Must match the identifier of an existing Snapshot.
     *

     *

     *

     *
     * @param snapshotIdentifier
     *        The identifier for the DB snapshot or DB cluster snapshot to restore from.

     *

     *        You can use either the name or the Amazon Resource Name (ARN) to specify a DB cluster snapshot. However,
     *        you can use only the ARN to specify a DB snapshot.
     *

     *

     *        Constraints:
     *

     *

     *

     *

     *        Must match the identifier of an existing Snapshot.
     *

     *

     * @return Returns a reference to this object so that method calls can be chained together.
     */

    public RestoreDBClusterFromSnapshotRequest withSnapshotIdentifier(String snapshotIdentifier) {
        setSnapshotIdentifier(snapshotIdentifier);
        return this;
    }

    /**
     *

     * The database engine to use for the new DB cluster.
     *

     *

     * Default: The same as source
     *

     *

     * Constraint: Must be compatible with the engine of the source
     *

     *
     * @param engine
     *        The database engine to use for the new DB cluster.

     *

     *        Default: The same as source
     *

     *

     *        Constraint: Must be compatible with the engine of the source
     */

    public void setEngine(String engine) {
        this.engine = engine;
    }

    /**
     *

     * The database engine to use for the new DB cluster.
     *

     *

     * Default: The same as source
     *

     *

     * Constraint: Must be compatible with the engine of the source
     *

     *
     * @return The database engine to use for the new DB cluster.

     *

     *         Default: The same as source
     *

     *

     *         Constraint: Must be compatible with the engine of the source
     */

    public String getEngine() {
        return this.engine;
    }

    /**
     *

     * The database engine to use for the new DB cluster.
     *

     *

     * Default: The same as source
     *

     *

     * Constraint: Must be compatible with the engine of the source
     *

     *
     * @param engine
     *        The database engine to use for the new DB cluster.

     *

     *        Default: The same as source
     *

     *

     *        Constraint: Must be compatible with the engine of the source
     * @return Returns a reference to this object so that method calls can be chained together.
     */

    public RestoreDBClusterFromSnapshotRequest withEngine(String engine) {
        setEngine(engine);
        return this;
    }

    /**
     *

     * The version of the database engine to use for the new DB cluster.
     *

     *
     * @param engineVersion
     *        The version of the database engine to use for the new DB cluster.
     */

    public void setEngineVersion(String engineVersion) {
        this.engineVersion = engineVersion;
    }

    /**
     *

     * The version of the database engine to use for the new DB cluster.
     *

     *
     * @return The version of the database engine to use for the new DB cluster.
     */

    public String getEngineVersion() {
        return this.engineVersion;
    }

    /**
     *

     * The version of the database engine to use for the new DB cluster.
     *

     *
     * @param engineVersion
     *        The version of the database engine to use for the new DB cluster.
     * @return Returns a reference to this object so that method calls can be chained together.
     */

    public RestoreDBClusterFromSnapshotRequest withEngineVersion(String engineVersion) {
        setEngineVersion(engineVersion);
        return this;
    }

    /**
     *

     * The port number on which the new DB cluster accepts connections.
     *

     *

     * Constraints: Value must be 1150-65535
     *

     *

     * Default: The same port as the original DB cluster.
     *

     *
     * @param port
     *        The port number on which the new DB cluster accepts connections.

     *

     *        Constraints: Value must be 1150-65535
     *

     *

     *        Default: The same port as the original DB cluster.
     */

    public void setPort(Integer port) {
        this.port = port;
    }

    /**
     *

     * The port number on which the new DB cluster accepts connections.
     *

     *

     * Constraints: Value must be 1150-65535
     *

     *

     * Default: The same port as the original DB cluster.
     *

     *
     * @return The port number on which the new DB cluster accepts connections.

     *

     *         Constraints: Value must be 1150-65535
     *

     *

     *         Default: The same port as the original DB cluster.
     */

    public Integer getPort() {
        return this.port;
    }

    /**
     *

     * The port number on which the new DB cluster accepts connections.
     *

     *

     * Constraints: Value must be 1150-65535
     *

     *

     * Default: The same port as the original DB cluster.
     *

     *
     * @param port
     *        The port number on which the new DB cluster accepts connections.

     *

     *        Constraints: Value must be 1150-65535
     *

     *

     *        Default: The same port as the original DB cluster.
     * @return Returns a reference to this object so that method calls can be chained together.
     */

    public RestoreDBClusterFromSnapshotRequest withPort(Integer port) {
        setPort(port);
        return this;
    }

    /**
     *

     * The name of the DB subnet group to use for the new DB cluster.
     *

     *

     * Constraints: If supplied, must match the name of an existing DBSubnetGroup.
     *

     *

     * Example: mySubnetgroup
     *

     *
     * @param dBSubnetGroupName
     *        The name of the DB subnet group to use for the new DB cluster.

     *

     *        Constraints: If supplied, must match the name of an existing DBSubnetGroup.
     *

     *

     *        Example: mySubnetgroup
     */

    public void setDBSubnetGroupName(String dBSubnetGroupName) {
        this.dBSubnetGroupName = dBSubnetGroupName;
    }

    /**
     *

     * The name of the DB subnet group to use for the new DB cluster.
     *

     *

     * Constraints: If supplied, must match the name of an existing DBSubnetGroup.
     *

     *

     * Example: mySubnetgroup
     *

     *
     * @return The name of the DB subnet group to use for the new DB cluster.

     *

     *         Constraints: If supplied, must match the name of an existing DBSubnetGroup.
     *

     *

     *         Example: mySubnetgroup
     */

    public String getDBSubnetGroupName() {
        return this.dBSubnetGroupName;
    }

    /**
     *

     * The name of the DB subnet group to use for the new DB cluster.
     *

     *

     * Constraints: If supplied, must match the name of an existing DBSubnetGroup.
     *

     *

     * Example: mySubnetgroup
     *

     *
     * @param dBSubnetGroupName
     *        The name of the DB subnet group to use for the new DB cluster.

     *

     *        Constraints: If supplied, must match the name of an existing DBSubnetGroup.
     *

     *

     *        Example: mySubnetgroup
     * @return Returns a reference to this object so that method calls can be chained together.
     */

    public RestoreDBClusterFromSnapshotRequest withDBSubnetGroupName(String dBSubnetGroupName) {
        setDBSubnetGroupName(dBSubnetGroupName);
        return this;
    }

    /**
     *

     * Not supported.
     *

     *
     * @param databaseName
     *        Not supported.
     */

    public void setDatabaseName(String databaseName) {
        this.databaseName = databaseName;
    }

    /**
     *

     * Not supported.
     *

     *
     * @return Not supported.
     */

    public String getDatabaseName() {
        return this.databaseName;
    }

    /**
     *

     * Not supported.
     *

     *
     * @param databaseName
     *        Not supported.
     * @return Returns a reference to this object so that method calls can be chained together.
     */

    public RestoreDBClusterFromSnapshotRequest withDatabaseName(String databaseName) {
        setDatabaseName(databaseName);
        return this;
    }

    /**
     *

     * (Not supported by Neptune)
     *

     *
     * @param optionGroupName
     *        (Not supported by Neptune)
     */

    public void setOptionGroupName(String optionGroupName) {
        this.optionGroupName = optionGroupName;
    }

    /**
     *

     * (Not supported by Neptune)
     *

     *
     * @return (Not supported by Neptune)
     */

    public String getOptionGroupName() {
        return this.optionGroupName;
    }

    /**
     *

     * (Not supported by Neptune)
     *

     *
     * @param optionGroupName
     *        (Not supported by Neptune)
     * @return Returns a reference to this object so that method calls can be chained together.
     */

    public RestoreDBClusterFromSnapshotRequest withOptionGroupName(String optionGroupName) {
        setOptionGroupName(optionGroupName);
        return this;
    }

    /**
     *

     * A list of VPC security groups that the new DB cluster will belong to.
     *

     *
     * @return A list of VPC security groups that the new DB cluster will belong to.
     */

    public java.util.List<String> getVpcSecurityGroupIds() {
        return vpcSecurityGroupIds;
    }

    /**
     *

     * A list of VPC security groups that the new DB cluster will belong to.
     *

     *
     * @param vpcSecurityGroupIds
     *        A list of VPC security groups that the new DB cluster will belong to.
     */

    public void setVpcSecurityGroupIds(java.util.Collection<String> vpcSecurityGroupIds) {
        if (vpcSecurityGroupIds == null) {
            this.vpcSecurityGroupIds = null;
            return;
        }

        this.vpcSecurityGroupIds = new java.util.ArrayList<String>(vpcSecurityGroupIds);
    }

    /**
     *

     * A list of VPC security groups that the new DB cluster will belong to.
     *

     *

     * NOTE: This method appends the values to the existing list (if any). Use
     * {@link #setVpcSecurityGroupIds(java.util.Collection)} or {@link #withVpcSecurityGroupIds(java.util.Collection)}
     * if you want to override the existing values.
     *

     *
     * @param vpcSecurityGroupIds
     *        A list of VPC security groups that the new DB cluster will belong to.
     * @return Returns a reference to this object so that method calls can be chained together.
     */

    public RestoreDBClusterFromSnapshotRequest withVpcSecurityGroupIds(String... vpcSecurityGroupIds) {
        if (this.vpcSecurityGroupIds == null) {
            setVpcSecurityGroupIds(new java.util.ArrayList<String>(vpcSecurityGroupIds.length));
        }
        for (String ele : vpcSecurityGroupIds) {
            this.vpcSecurityGroupIds.add(ele);
        }
        return this;
    }

    /**
     *

     * A list of VPC security groups that the new DB cluster will belong to.
     *

     *
     * @param vpcSecurityGroupIds
     *        A list of VPC security groups that the new DB cluster will belong to.
     * @return Returns a reference to this object so that method calls can be chained together.
     */

    public RestoreDBClusterFromSnapshotRequest withVpcSecurityGroupIds(java.util.Collection<String> vpcSecurityGroupIds) {
        setVpcSecurityGroupIds(vpcSecurityGroupIds);
        return this;
    }

    /**
     *

     * The tags to be assigned to the restored DB cluster.
     *

     *
     * @return The tags to be assigned to the restored DB cluster.
     */

    public java.util.List<Tag> getTags() {
        return tags;
    }

    /**
     *

     * The tags to be assigned to the restored DB cluster.
     *

     *
     * @param tags
     *        The tags to be assigned to the restored DB cluster.
     */

    public void setTags(java.util.Collection<Tag> tags) {
        if (tags == null) {
            this.tags = null;
            return;
        }

        this.tags = new java.util.ArrayList<Tag>(tags);
    }

    /**
     *

     * The tags to be assigned to the restored DB cluster.
     *

     *

     * 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
     *        The tags to be assigned to the restored DB cluster.
     * @return Returns a reference to this object so that method calls can be chained together.
     */

    public RestoreDBClusterFromSnapshotRequest withTags(Tag... tags) {
        if (this.tags == null) {
            setTags(new java.util.ArrayList<Tag>(tags.length));
        }
        for (Tag ele : tags) {
            this.tags.add(ele);
        }
        return this;
    }

    /**
     *

     * The tags to be assigned to the restored DB cluster.
     *

     *
     * @param tags
     *        The tags to be assigned to the restored DB cluster.
     * @return Returns a reference to this object so that method calls can be chained together.
     */

    public RestoreDBClusterFromSnapshotRequest withTags(java.util.Collection<Tag> tags) {
        setTags(tags);
        return this;
    }

    /**
     *

     * The Amazon KMS key identifier to use when restoring an encrypted DB cluster from a DB snapshot or DB cluster
     * snapshot.
     *

     *

     * The KMS key identifier is the Amazon Resource Name (ARN) for the KMS encryption key. If you are restoring a DB
     * cluster with the same Amazon account that owns the KMS encryption key used to encrypt the new DB cluster, then
     * you can use the KMS key alias instead of the ARN for the KMS encryption key.
     *

     *

     * If you do not specify a value for the KmsKeyId parameter, then the following will occur:
     *

     *

     *

     *

     * If the DB snapshot or DB cluster snapshot in SnapshotIdentifier is encrypted, then the restored DB
     * cluster is encrypted using the KMS key that was used to encrypt the DB snapshot or DB cluster snapshot.
     *

     *

     *

     *

     * If the DB snapshot or DB cluster snapshot in SnapshotIdentifier is not encrypted, then the restored
     * DB cluster is not encrypted.
     *

     *

     *

     *
     * @param kmsKeyId
     *        The Amazon KMS key identifier to use when restoring an encrypted DB cluster from a DB snapshot or DB
     *        cluster snapshot.

     *

     *        The KMS key identifier is the Amazon Resource Name (ARN) for the KMS encryption key. If you are restoring
     *        a DB cluster with the same Amazon account that owns the KMS encryption key used to encrypt the new DB
     *        cluster, then you can use the KMS key alias instead of the ARN for the KMS encryption key.
     *

     *

     *        If you do not specify a value for the KmsKeyId parameter, then the following will occur:
     *

     *

     *

     *

     *        If the DB snapshot or DB cluster snapshot in SnapshotIdentifier is encrypted, then the
     *        restored DB cluster is encrypted using the KMS key that was used to encrypt the DB snapshot or DB cluster
     *        snapshot.
     *

     *

     *

     *

     *        If the DB snapshot or DB cluster snapshot in SnapshotIdentifier is not encrypted, then the
     *        restored DB cluster is not encrypted.
     *

     *

     */

    public void setKmsKeyId(String kmsKeyId) {
        this.kmsKeyId = kmsKeyId;
    }

    /**
     *

     * The Amazon KMS key identifier to use when restoring an encrypted DB cluster from a DB snapshot or DB cluster
     * snapshot.
     *

     *

     * The KMS key identifier is the Amazon Resource Name (ARN) for the KMS encryption key. If you are restoring a DB
     * cluster with the same Amazon account that owns the KMS encryption key used to encrypt the new DB cluster, then
     * you can use the KMS key alias instead of the ARN for the KMS encryption key.
     *

     *

     * If you do not specify a value for the KmsKeyId parameter, then the following will occur:
     *

     *

     *

     *

     * If the DB snapshot or DB cluster snapshot in SnapshotIdentifier is encrypted, then the restored DB
     * cluster is encrypted using the KMS key that was used to encrypt the DB snapshot or DB cluster snapshot.
     *

     *

     *

     *

     * If the DB snapshot or DB cluster snapshot in SnapshotIdentifier is not encrypted, then the restored
     * DB cluster is not encrypted.
     *

     *

     *

     *
     * @return The Amazon KMS key identifier to use when restoring an encrypted DB cluster from a DB snapshot or DB
     *         cluster snapshot.

     *

     *         The KMS key identifier is the Amazon Resource Name (ARN) for the KMS encryption key. If you are restoring
     *         a DB cluster with the same Amazon account that owns the KMS encryption key used to encrypt the new DB
     *         cluster, then you can use the KMS key alias instead of the ARN for the KMS encryption key.
     *

     *

     *         If you do not specify a value for the KmsKeyId parameter, then the following will occur:
     *

     *

     *

     *

     *         If the DB snapshot or DB cluster snapshot in SnapshotIdentifier is encrypted, then the
     *         restored DB cluster is encrypted using the KMS key that was used to encrypt the DB snapshot or DB cluster
     *         snapshot.
     *

     *

     *

     *

     *         If the DB snapshot or DB cluster snapshot in SnapshotIdentifier is not encrypted, then the
     *         restored DB cluster is not encrypted.
     *

     *

     */

    public String getKmsKeyId() {
        return this.kmsKeyId;
    }

    /**
     *

     * The Amazon KMS key identifier to use when restoring an encrypted DB cluster from a DB snapshot or DB cluster
     * snapshot.
     *

     *

     * The KMS key identifier is the Amazon Resource Name (ARN) for the KMS encryption key. If you are restoring a DB
     * cluster with the same Amazon account that owns the KMS encryption key used to encrypt the new DB cluster, then
     * you can use the KMS key alias instead of the ARN for the KMS encryption key.
     *

     *

     * If you do not specify a value for the KmsKeyId parameter, then the following will occur:
     *

     *

     *

     *

     * If the DB snapshot or DB cluster snapshot in SnapshotIdentifier is encrypted, then the restored DB
     * cluster is encrypted using the KMS key that was used to encrypt the DB snapshot or DB cluster snapshot.
     *

     *

     *

     *

     * If the DB snapshot or DB cluster snapshot in SnapshotIdentifier is not encrypted, then the restored
     * DB cluster is not encrypted.
     *

     *

     *

     *
     * @param kmsKeyId
     *        The Amazon KMS key identifier to use when restoring an encrypted DB cluster from a DB snapshot or DB
     *        cluster snapshot.

     *

     *        The KMS key identifier is the Amazon Resource Name (ARN) for the KMS encryption key. If you are restoring
     *        a DB cluster with the same Amazon account that owns the KMS encryption key used to encrypt the new DB
     *        cluster, then you can use the KMS key alias instead of the ARN for the KMS encryption key.
     *

     *

     *        If you do not specify a value for the KmsKeyId parameter, then the following will occur:
     *

     *

     *

     *

     *        If the DB snapshot or DB cluster snapshot in SnapshotIdentifier is encrypted, then the
     *        restored DB cluster is encrypted using the KMS key that was used to encrypt the DB snapshot or DB cluster
     *        snapshot.
     *

     *

     *

     *

     *        If the DB snapshot or DB cluster snapshot in SnapshotIdentifier is not encrypted, then the
     *        restored DB cluster is not encrypted.
     *

     *

     * @return Returns a reference to this object so that method calls can be chained together.
     */

    public RestoreDBClusterFromSnapshotRequest withKmsKeyId(String kmsKeyId) {
        setKmsKeyId(kmsKeyId);
        return this;
    }

    /**
     *

     * True to enable mapping of Amazon Identity and Access Management (IAM) accounts to database accounts, and
     * otherwise false.
     *

     *

     * Default: false
     *

     *
     * @param enableIAMDatabaseAuthentication
     *        True to enable mapping of Amazon Identity and Access Management (IAM) accounts to database accounts, and
     *        otherwise false.

     *

     *        Default: false
     */

    public void setEnableIAMDatabaseAuthentication(Boolean enableIAMDatabaseAuthentication) {
        this.enableIAMDatabaseAuthentication = enableIAMDatabaseAuthentication;
    }

    /**
     *

     * True to enable mapping of Amazon Identity and Access Management (IAM) accounts to database accounts, and
     * otherwise false.
     *

     *

     * Default: false
     *

     *
     * @return True to enable mapping of Amazon Identity and Access Management (IAM) accounts to database accounts, and
     *         otherwise false.

     *

     *         Default: false
     */

    public Boolean getEnableIAMDatabaseAuthentication() {
        return this.enableIAMDatabaseAuthentication;
    }

    /**
     *

     * True to enable mapping of Amazon Identity and Access Management (IAM) accounts to database accounts, and
     * otherwise false.
     *

     *

     * Default: false
     *

     *
     * @param enableIAMDatabaseAuthentication
     *        True to enable mapping of Amazon Identity and Access Management (IAM) accounts to database accounts, and
     *        otherwise false.

     *

     *        Default: false
     * @return Returns a reference to this object so that method calls can be chained together.
     */

    public RestoreDBClusterFromSnapshotRequest withEnableIAMDatabaseAuthentication(Boolean enableIAMDatabaseAuthentication) {
        setEnableIAMDatabaseAuthentication(enableIAMDatabaseAuthentication);
        return this;
    }

    /**
     *

     * True to enable mapping of Amazon Identity and Access Management (IAM) accounts to database accounts, and
     * otherwise false.
     *

     *

     * Default: false
     *

     *
     * @return True to enable mapping of Amazon Identity and Access Management (IAM) accounts to database accounts, and
     *         otherwise false.

     *

     *         Default: false
     */

    public Boolean isEnableIAMDatabaseAuthentication() {
        return this.enableIAMDatabaseAuthentication;
    }

    /**
     *

     * The list of logs that the restored DB cluster is to export to Amazon CloudWatch Logs.
     *

     *
     * @return The list of logs that the restored DB cluster is to export to Amazon CloudWatch Logs.
     */

    public java.util.List<String> getEnableCloudwatchLogsExports() {
        return enableCloudwatchLogsExports;
    }

    /**
     *

     * The list of logs that the restored DB cluster is to export to Amazon CloudWatch Logs.
     *

     *
     * @param enableCloudwatchLogsExports
     *        The list of logs that the restored DB cluster is to export to Amazon CloudWatch Logs.
     */

    public void setEnableCloudwatchLogsExports(java.util.Collection<String> enableCloudwatchLogsExports) {
        if (enableCloudwatchLogsExports == null) {
            this.enableCloudwatchLogsExports = null;
            return;
        }

        this.enableCloudwatchLogsExports = new java.util.ArrayList<String>(enableCloudwatchLogsExports);
    }

    /**
     *

     * The list of logs that the restored DB cluster is to export to Amazon CloudWatch Logs.
     *

     *

     * NOTE: This method appends the values to the existing list (if any). Use
     * {@link #setEnableCloudwatchLogsExports(java.util.Collection)} or
     * {@link #withEnableCloudwatchLogsExports(java.util.Collection)} if you want to override the existing values.
     *

     *
     * @param enableCloudwatchLogsExports
     *        The list of logs that the restored DB cluster is to export to Amazon CloudWatch Logs.
     * @return Returns a reference to this object so that method calls can be chained together.
     */

    public RestoreDBClusterFromSnapshotRequest withEnableCloudwatchLogsExports(String... enableCloudwatchLogsExports) {
        if (this.enableCloudwatchLogsExports == null) {
            setEnableCloudwatchLogsExports(new java.util.ArrayList<String>(enableCloudwatchLogsExports.length));
        }
        for (String ele : enableCloudwatchLogsExports) {
            this.enableCloudwatchLogsExports.add(ele);
        }
        return this;
    }

    /**
     *

     * The list of logs that the restored DB cluster is to export to Amazon CloudWatch Logs.
     *

     *
     * @param enableCloudwatchLogsExports
     *        The list of logs that the restored DB cluster is to export to Amazon CloudWatch Logs.
     * @return Returns a reference to this object so that method calls can be chained together.
     */

    public RestoreDBClusterFromSnapshotRequest withEnableCloudwatchLogsExports(java.util.Collection<String> enableCloudwatchLogsExports) {
        setEnableCloudwatchLogsExports(enableCloudwatchLogsExports);
        return this;
    }

    /**
     *

     * The name of the DB cluster parameter group to associate with the new DB cluster.
     *

     *

     * Constraints:
     *

     *

     *

     *

     * If supplied, must match the name of an existing DBClusterParameterGroup.
     *

     *

     *

     *
     * @param dBClusterParameterGroupName
     *        The name of the DB cluster parameter group to associate with the new DB cluster.

     *

     *        Constraints:
     *

     *

     *

     *

     *        If supplied, must match the name of an existing DBClusterParameterGroup.
     *

     *

     */

    public void setDBClusterParameterGroupName(String dBClusterParameterGroupName) {
        this.dBClusterParameterGroupName = dBClusterParameterGroupName;
    }

    /**
     *

     * The name of the DB cluster parameter group to associate with the new DB cluster.
     *

     *

     * Constraints:
     *

     *

     *

     *

     * If supplied, must match the name of an existing DBClusterParameterGroup.
     *

     *

     *

     *
     * @return The name of the DB cluster parameter group to associate with the new DB cluster.

     *

     *         Constraints:
     *

     *

     *

     *

     *         If supplied, must match the name of an existing DBClusterParameterGroup.
     *

     *

     */

    public String getDBClusterParameterGroupName() {
        return this.dBClusterParameterGroupName;
    }

    /**
     *

     * The name of the DB cluster parameter group to associate with the new DB cluster.
     *

     *

     * Constraints:
     *

     *

     *

     *

     * If supplied, must match the name of an existing DBClusterParameterGroup.
     *

     *

     *

     *
     * @param dBClusterParameterGroupName
     *        The name of the DB cluster parameter group to associate with the new DB cluster.

     *

     *        Constraints:
     *

     *

     *

     *

     *        If supplied, must match the name of an existing DBClusterParameterGroup.
     *

     *

     * @return Returns a reference to this object so that method calls can be chained together.
     */

    public RestoreDBClusterFromSnapshotRequest withDBClusterParameterGroupName(String dBClusterParameterGroupName) {
        setDBClusterParameterGroupName(dBClusterParameterGroupName);
        return this;
    }

    /**
     *

     * A value that indicates whether the DB cluster has deletion protection enabled. The database can't be deleted when
     * deletion protection is enabled. By default, deletion protection is disabled.
     *

     *
     * @param deletionProtection
     *        A value that indicates whether the DB cluster has deletion protection enabled. The database can't be
     *        deleted when deletion protection is enabled. By default, deletion protection is disabled.
     */

    public void setDeletionProtection(Boolean deletionProtection) {
        this.deletionProtection = deletionProtection;
    }

    /**
     *

     * A value that indicates whether the DB cluster has deletion protection enabled. The database can't be deleted when
     * deletion protection is enabled. By default, deletion protection is disabled.
     *

     *
     * @return A value that indicates whether the DB cluster has deletion protection enabled. The database can't be
     *         deleted when deletion protection is enabled. By default, deletion protection is disabled.
     */

    public Boolean getDeletionProtection() {
        return this.deletionProtection;
    }

    /**
     *

     * A value that indicates whether the DB cluster has deletion protection enabled. The database can't be deleted when
     * deletion protection is enabled. By default, deletion protection is disabled.
     *

     *
     * @param deletionProtection
     *        A value that indicates whether the DB cluster has deletion protection enabled. The database can't be
     *        deleted when deletion protection is enabled. By default, deletion protection is disabled.
     * @return Returns a reference to this object so that method calls can be chained together.
     */

    public RestoreDBClusterFromSnapshotRequest withDeletionProtection(Boolean deletionProtection) {
        setDeletionProtection(deletionProtection);
        return this;
    }

    /**
     *

     * A value that indicates whether the DB cluster has deletion protection enabled. The database can't be deleted when
     * deletion protection is enabled. By default, deletion protection is disabled.
     *

     *
     * @return A value that indicates whether the DB cluster has deletion protection enabled. The database can't be
     *         deleted when deletion protection is enabled. By default, deletion protection is disabled.
     */

    public Boolean isDeletionProtection() {
        return this.deletionProtection;
    }

    /**
     *

     * If set to true, tags are copied to any snapshot of the restored DB cluster that is created.
     *

     *
     * @param copyTagsToSnapshot
     *        If set to true, tags are copied to any snapshot of the restored DB cluster that is
     *        created.
     */

    public void setCopyTagsToSnapshot(Boolean copyTagsToSnapshot) {
        this.copyTagsToSnapshot = copyTagsToSnapshot;
    }

    /**
     *

     * If set to true, tags are copied to any snapshot of the restored DB cluster that is created.
     *

     *
     * @return If set to true, tags are copied to any snapshot of the restored DB cluster that is
     *         created.
     */

    public Boolean getCopyTagsToSnapshot() {
        return this.copyTagsToSnapshot;
    }

    /**
     *

     * If set to true, tags are copied to any snapshot of the restored DB cluster that is created.
     *

     *
     * @param copyTagsToSnapshot
     *        If set to true, tags are copied to any snapshot of the restored DB cluster that is
     *        created.
     * @return Returns a reference to this object so that method calls can be chained together.
     */

    public RestoreDBClusterFromSnapshotRequest withCopyTagsToSnapshot(Boolean copyTagsToSnapshot) {
        setCopyTagsToSnapshot(copyTagsToSnapshot);
        return this;
    }

    /**
     *

     * If set to true, tags are copied to any snapshot of the restored DB cluster that is created.
     *

     *
     * @return If set to true, tags are copied to any snapshot of the restored DB cluster that is
     *         created.
     */

    public Boolean isCopyTagsToSnapshot() {
        return this.copyTagsToSnapshot;
    }

    /**
     * @param serverlessV2ScalingConfiguration
     */

    public void setServerlessV2ScalingConfiguration(ServerlessV2ScalingConfiguration serverlessV2ScalingConfiguration) {
        this.serverlessV2ScalingConfiguration = serverlessV2ScalingConfiguration;
    }

    /**
     * @return
     */

    public ServerlessV2ScalingConfiguration getServerlessV2ScalingConfiguration() {
        return this.serverlessV2ScalingConfiguration;
    }

    /**
     * @param serverlessV2ScalingConfiguration
     * @return Returns a reference to this object so that method calls can be chained together.
     */

    public RestoreDBClusterFromSnapshotRequest withServerlessV2ScalingConfiguration(ServerlessV2ScalingConfiguration serverlessV2ScalingConfiguration) {
        setServerlessV2ScalingConfiguration(serverlessV2ScalingConfiguration);
        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 (getAvailabilityZones() != null)
            sb.append("AvailabilityZones: ").append(getAvailabilityZones()).append(",");
        if (getDBClusterIdentifier() != null)
            sb.append("DBClusterIdentifier: ").append(getDBClusterIdentifier()).append(",");
        if (getSnapshotIdentifier() != null)
            sb.append("SnapshotIdentifier: ").append(getSnapshotIdentifier()).append(",");
        if (getEngine() != null)
            sb.append("Engine: ").append(getEngine()).append(",");
        if (getEngineVersion() != null)
            sb.append("EngineVersion: ").append(getEngineVersion()).append(",");
        if (getPort() != null)
            sb.append("Port: ").append(getPort()).append(",");
        if (getDBSubnetGroupName() != null)
            sb.append("DBSubnetGroupName: ").append(getDBSubnetGroupName()).append(",");
        if (getDatabaseName() != null)
            sb.append("DatabaseName: ").append(getDatabaseName()).append(",");
        if (getOptionGroupName() != null)
            sb.append("OptionGroupName: ").append(getOptionGroupName()).append(",");
        if (getVpcSecurityGroupIds() != null)
            sb.append("VpcSecurityGroupIds: ").append(getVpcSecurityGroupIds()).append(",");
        if (getTags() != null)
            sb.append("Tags: ").append(getTags()).append(",");
        if (getKmsKeyId() != null)
            sb.append("KmsKeyId: ").append(getKmsKeyId()).append(",");
        if (getEnableIAMDatabaseAuthentication() != null)
            sb.append("EnableIAMDatabaseAuthentication: ").append(getEnableIAMDatabaseAuthentication()).append(",");
        if (getEnableCloudwatchLogsExports() != null)
            sb.append("EnableCloudwatchLogsExports: ").append(getEnableCloudwatchLogsExports()).append(",");
        if (getDBClusterParameterGroupName() != null)
            sb.append("DBClusterParameterGroupName: ").append(getDBClusterParameterGroupName()).append(",");
        if (getDeletionProtection() != null)
            sb.append("DeletionProtection: ").append(getDeletionProtection()).append(",");
        if (getCopyTagsToSnapshot() != null)
            sb.append("CopyTagsToSnapshot: ").append(getCopyTagsToSnapshot()).append(",");
        if (getServerlessV2ScalingConfiguration() != null)
            sb.append("ServerlessV2ScalingConfiguration: ").append(getServerlessV2ScalingConfiguration());
        sb.append("}");
        return sb.toString();
    }

    @Override
    public boolean equals(Object obj) {
        if (this == obj)
            return true;
        if (obj == null)
            return false;

        if (obj instanceof RestoreDBClusterFromSnapshotRequest == false)
            return false;
        RestoreDBClusterFromSnapshotRequest other = (RestoreDBClusterFromSnapshotRequest) obj;
        if (other.getAvailabilityZones() == null ^ this.getAvailabilityZones() == null)
            return false;
        if (other.getAvailabilityZones() != null && other.getAvailabilityZones().equals(this.getAvailabilityZones()) == false)
            return false;
        if (other.getDBClusterIdentifier() == null ^ this.getDBClusterIdentifier() == null)
            return false;
        if (other.getDBClusterIdentifier() != null && other.getDBClusterIdentifier().equals(this.getDBClusterIdentifier()) == false)
            return false;
        if (other.getSnapshotIdentifier() == null ^ this.getSnapshotIdentifier() == null)
            return false;
        if (other.getSnapshotIdentifier() != null && other.getSnapshotIdentifier().equals(this.getSnapshotIdentifier()) == false)
            return false;
        if (other.getEngine() == null ^ this.getEngine() == null)
            return false;
        if (other.getEngine() != null && other.getEngine().equals(this.getEngine()) == false)
            return false;
        if (other.getEngineVersion() == null ^ this.getEngineVersion() == null)
            return false;
        if (other.getEngineVersion() != null && other.getEngineVersion().equals(this.getEngineVersion()) == false)
            return false;
        if (other.getPort() == null ^ this.getPort() == null)
            return false;
        if (other.getPort() != null && other.getPort().equals(this.getPort()) == false)
            return false;
        if (other.getDBSubnetGroupName() == null ^ this.getDBSubnetGroupName() == null)
            return false;
        if (other.getDBSubnetGroupName() != null && other.getDBSubnetGroupName().equals(this.getDBSubnetGroupName()) == false)
            return false;
        if (other.getDatabaseName() == null ^ this.getDatabaseName() == null)
            return false;
        if (other.getDatabaseName() != null && other.getDatabaseName().equals(this.getDatabaseName()) == false)
            return false;
        if (other.getOptionGroupName() == null ^ this.getOptionGroupName() == null)
            return false;
        if (other.getOptionGroupName() != null && other.getOptionGroupName().equals(this.getOptionGroupName()) == false)
            return false;
        if (other.getVpcSecurityGroupIds() == null ^ this.getVpcSecurityGroupIds() == null)
            return false;
        if (other.getVpcSecurityGroupIds() != null && other.getVpcSecurityGroupIds().equals(this.getVpcSecurityGroupIds()) == false)
            return false;
        if (other.getTags() == null ^ this.getTags() == null)
            return false;
        if (other.getTags() != null && other.getTags().equals(this.getTags()) == false)
            return false;
        if (other.getKmsKeyId() == null ^ this.getKmsKeyId() == null)
            return false;
        if (other.getKmsKeyId() != null && other.getKmsKeyId().equals(this.getKmsKeyId()) == false)
            return false;
        if (other.getEnableIAMDatabaseAuthentication() == null ^ this.getEnableIAMDatabaseAuthentication() == null)
            return false;
        if (other.getEnableIAMDatabaseAuthentication() != null
                && other.getEnableIAMDatabaseAuthentication().equals(this.getEnableIAMDatabaseAuthentication()) == false)
            return false;
        if (other.getEnableCloudwatchLogsExports() == null ^ this.getEnableCloudwatchLogsExports() == null)
            return false;
        if (other.getEnableCloudwatchLogsExports() != null && other.getEnableCloudwatchLogsExports().equals(this.getEnableCloudwatchLogsExports()) == false)
            return false;
        if (other.getDBClusterParameterGroupName() == null ^ this.getDBClusterParameterGroupName() == null)
            return false;
        if (other.getDBClusterParameterGroupName() != null && other.getDBClusterParameterGroupName().equals(this.getDBClusterParameterGroupName()) == false)
            return false;
        if (other.getDeletionProtection() == null ^ this.getDeletionProtection() == null)
            return false;
        if (other.getDeletionProtection() != null && other.getDeletionProtection().equals(this.getDeletionProtection()) == false)
            return false;
        if (other.getCopyTagsToSnapshot() == null ^ this.getCopyTagsToSnapshot() == null)
            return false;
        if (other.getCopyTagsToSnapshot() != null && other.getCopyTagsToSnapshot().equals(this.getCopyTagsToSnapshot()) == false)
            return false;
        if (other.getServerlessV2ScalingConfiguration() == null ^ this.getServerlessV2ScalingConfiguration() == null)
            return false;
        if (other.getServerlessV2ScalingConfiguration() != null
                && other.getServerlessV2ScalingConfiguration().equals(this.getServerlessV2ScalingConfiguration()) == false)
            return false;
        return true;
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int hashCode = 1;

        hashCode = prime * hashCode + ((getAvailabilityZones() == null) ? 0 : getAvailabilityZones().hashCode());
        hashCode = prime * hashCode + ((getDBClusterIdentifier() == null) ? 0 : getDBClusterIdentifier().hashCode());
        hashCode = prime * hashCode + ((getSnapshotIdentifier() == null) ? 0 : getSnapshotIdentifier().hashCode());
        hashCode = prime * hashCode + ((getEngine() == null) ? 0 : getEngine().hashCode());
        hashCode = prime * hashCode + ((getEngineVersion() == null) ? 0 : getEngineVersion().hashCode());
        hashCode = prime * hashCode + ((getPort() == null) ? 0 : getPort().hashCode());
        hashCode = prime * hashCode + ((getDBSubnetGroupName() == null) ? 0 : getDBSubnetGroupName().hashCode());
        hashCode = prime * hashCode + ((getDatabaseName() == null) ? 0 : getDatabaseName().hashCode());
        hashCode = prime * hashCode + ((getOptionGroupName() == null) ? 0 : getOptionGroupName().hashCode());
        hashCode = prime * hashCode + ((getVpcSecurityGroupIds() == null) ? 0 : getVpcSecurityGroupIds().hashCode());
        hashCode = prime * hashCode + ((getTags() == null) ? 0 : getTags().hashCode());
        hashCode = prime * hashCode + ((getKmsKeyId() == null) ? 0 : getKmsKeyId().hashCode());
        hashCode = prime * hashCode + ((getEnableIAMDatabaseAuthentication() == null) ? 0 : getEnableIAMDatabaseAuthentication().hashCode());
        hashCode = prime * hashCode + ((getEnableCloudwatchLogsExports() == null) ? 0 : getEnableCloudwatchLogsExports().hashCode());
        hashCode = prime * hashCode + ((getDBClusterParameterGroupName() == null) ? 0 : getDBClusterParameterGroupName().hashCode());
        hashCode = prime * hashCode + ((getDeletionProtection() == null) ? 0 : getDeletionProtection().hashCode());
        hashCode = prime * hashCode + ((getCopyTagsToSnapshot() == null) ? 0 : getCopyTagsToSnapshot().hashCode());
        hashCode = prime * hashCode + ((getServerlessV2ScalingConfiguration() == null) ? 0 : getServerlessV2ScalingConfiguration().hashCode());
        return hashCode;
    }

    @Override
    public RestoreDBClusterFromSnapshotRequest clone() {
        return (RestoreDBClusterFromSnapshotRequest) super.clone();
    }

}


text:
# ParamNameMismatch

Emitted when method overrides a parent method but renames a param.

```php
<?php

class A {
    public function foo(string $str, bool $b = false) : void {}
}

class AChild extends A {
    public function foo(string $string, bool $b = false) : void {}
}
```

## Why is this bad?

PHP 8 introduces [named parameters](https://wiki.php.net/rfc/named_params) which allow developers to call methods with explicitly-named parameters;

```php
<?php

function callFoo(A $a) {
    $a->foo(str: "hello");
}
```

In the first example passing `new AChild()` to `callFoo()` results in a fatal error, as AChild's definition of the method `foo()` doesn't have a parameter named `$str`.

## How to fix

You can change the child method param name to match:

```php
<?php

class A {
    public function foo(string $str, bool $b = false) : void {}
}

class AChild extends A {
    public function foo(string $str, bool $b = false) : void {}
}
```

This fix [can be applied automatically by Psalter](https://psalm.dev/docs/manipulating_code/fixing/#paramnamemismatch).

## Workarounds

### @no-named-arguments

Alternatively you can ignore this issue by adding a `@no-named-arguments` annotation to the parent method:

```php
<?php

class A {
    /** @no-named-arguments */
    public function foo(string $str, bool $b = false) : void {}
}

class AChild extends A {
    public function foo(string $string, bool $b = false) : void {}
}
```

Any method with this annotation will be prevented (by Psalm) from being called with named parameters, so the original issue does not matter.

### Config allowNamedArgumentCalls="false"

This prevents any use of named params in your codebase. Ideal for self-contained projects, but less ideal for libraries.

It means the original code above will not emit any errors as long as the class `A` is defined in a directory that Psalm can scan.

### Config allowInternalNamedArgumentCalls="false"

For library authors Psalm supports a more nuanced flag that tells Psalm to prohibit any named parameter calls on `@internal` classes or methods.

With that config value, this is now allowed:

```php
<?php

/**
 * @internal
 */
class A {
    public function foo(string $str, bool $b = false) : void {}
}

class AChild extends A {
    public function foo(string $string, bool $b = false) : void {}
}
```

redpajama_set_name: RedPajamaGithub


text:
var PromisifyMe = require('../index');

var TwitDefinition = {
  get : PromisifyMe.promisifyCallbackFn,
  post : PromisifyMe.promisifyCallbackFn,
  getAuth : PromisifyMe.dontPromisify,
  setAuth : PromisifyMe.dontPromisify,
  stream : PromisifyMe.dontPromisify
};

module.exports = TwitDefinition;


text:
import logging
import socket
import platform
if platform.system()=='Java':
	import com.xhaus.jyson.JysonCodec as json
else:
	import json
import email.parser

class SmtpMsgmtException(Exception):  pass

class SmtpMgmtClient():
    __socket = None
    __socket_file = None

    def __init__(self, host, port):
        self.received_data = []
        self.logger = logging.getLogger('SmtpMgmtClient')
        self.__socket = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
        self.logger.debug('connecting to %s', (host, port))
        self.__socket.connect((host, port))

        self.__socket_file = self.__socket.makefile('rw',0)
        result = self.read_response()

        self.__helo()

    def send_command(self, command, args=None):
      self.logger.debug('sending "%s"' % command)
      self.received_data = []
      if args:
        self.__socket.sendall('%s %s\r\n' % (command, args) )
      else:
        self.__socket.sendall('%s\r\n' % command)

    def read_response(self):
      line = self.__socket_file.readline()
      line = line.strip()
      self.logger.debug('recieved: "%s"' % line)
      ll = line.split()
      code = int(ll[0])
      rest = ' '.join(ll[1:])

      #self.logger.debug('code: %d' % int(code) )
      #self.logger.debug('rest: %s' % rest )

      if code == 100:
        # connect / handshake
        self.logger.info('Host >> %s <<' % rest )
        return rest

      if code == 200:
        # Command ok. Data in number of bytes given
        bytecnt = int(rest)
        self.logger.debug('Byte count: %d' % bytecnt )
        result = self.__socket_file.read(bytecnt)
        return result

      if code == 210:
        # Command ok. Data in number of lines given
        linecnt = int(rest)
        self.logger.debug('Line count: %d' % linecnt )

        lines = []
        for i in range(linecnt):
          line = self.__socket_file.readline()
          line = line.rstrip()
          self.logger.debug('line: %s' % line)
          lines.append(line)

        return lines

      if code == 250:
        # Command ok. No data returned
        self.logger.info('Result: %s' % rest )
        return rest

      if code == 500:
        # error
        raise SmtpMsgmtException(rest)
        return None

    def __helo(self, msg='SmtpMgmtClient'):
      self.send_command('HELO', msg )
      return self.read_response()

    def noop(self):
      self.send_command('NOOP')
      return self.read_response()

    def echo(self, msg='Echo'):
      self.send_command('ECHO', msg)
      return self.read_response()

    def reset(self):
      self.send_command('RESET')
      result = self.read_response()
      return

    def msgcnt(self, recipient):
      self.send_command('MSGCNT', recipient)
      result = self.read_response()
      return int(result)

    def msglst(self, recipient, mode=None):
      if mode:
        self.send_command('MSGLST', '%s %s' % (recipient, mode) )
      else:
        self.send_command('MSGLST', recipient)
      result = self.read_response()

      if mode == 'json':
        if result:
          d = json.loads(result)
        else:
          d = []

      else:
        d = []

        for line in result:
          d.append(line.strip()[4:])

      return d

    def msgget(self, recipient, msgid, mode=None):
      if mode:
        self.send_command('MSGGET', '%s %d %s' % (recipient, msgid, mode) )
      else:
        self.send_command('MSGGET', '%s %d' % (recipient, msgid))
      result = self.read_response()

      if mode == 'json':
        if result:
          d = json.loads(result)
        else:
          d = {}

      if mode == 'mime':
        fp = email.parser.Parser()
        print result
        msg = fp.parsestr(result)
        d = msg

      else:
        d = result

      return d

    def dump(self, mode=None):

      self.send_command('DUMP', mode)
      result = self.read_response()

      if result == 'No entries':
        return None

      if mode == 'json':
        d = json.loads(result)

      else:
        d = {}

        for line in result:
          if line[0] == '\t':
            d[rcpt].append(line.strip()[4:])
          else:
            rcpt = line[:-1]
            d[rcpt] = []

      return d