"""Raw representations of every data type in the AWS RDS service.

See Also:
    `AWS developer guide for RDS
    <https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/index.html>`_

This file is automatically generated, and should not be directly edited.
"""

from attr import attrib
from attr import attrs

from ..core import ATTRSCONFIG
from ..core import Resource
from ..core import ResourceProperties
from ..core import create_object_converter

__all__ = [
    "DBCluster",
    "DBClusterProperties",
    "DBClusterParameterGroup",
    "DBClusterParameterGroupProperties",
    "DBInstance",
    "DBInstanceProperties",
    "DBParameterGroup",
    "DBParameterGroupProperties",
    "DBSecurityGroup",
    "DBSecurityGroupProperties",
    "DBSecurityGroupIngress",
    "DBSecurityGroupIngressProperties",
    "DBSubnetGroup",
    "DBSubnetGroupProperties",
    "EventSubscription",
    "EventSubscriptionProperties",
    "OptionGroup",
    "OptionGroupProperties",
]


@attrs(**ATTRSCONFIG)
class DBClusterProperties(ResourceProperties):
    AvailabilityZones = attrib(default=None)
    BacktrackWindow = attrib(default=None)
    BackupRetentionPeriod = attrib(default=None)
    DatabaseName = attrib(default=None)
    DBClusterIdentifier = attrib(default=None)
    DBClusterParameterGroupName = attrib(default=None)
    DBSubnetGroupName = attrib(default=None)
    DeletionProtection = attrib(default=None)
    EnableCloudwatchLogsExports = attrib(default=None)
    EnableIAMDatabaseAuthentication = attrib(default=None)
    Engine = attrib(default=None)
    EngineMode = attrib(default=None)
    EngineVersion = attrib(default=None)
    KmsKeyId = attrib(default=None)
    MasterUsername = attrib(default=None)
    MasterUserPassword = attrib(default=None)
    Port = attrib(default=None)
    PreferredBackupWindow = attrib(default=None)
    PreferredMaintenanceWindow = attrib(default=None)
    ReplicationSourceIdentifier = attrib(default=None)
    ScalingConfiguration = attrib(default=None)
    SnapshotIdentifier = attrib(default=None)
    SourceRegion = attrib(default=None)
    StorageEncrypted = attrib(default=None)
    Tags = attrib(default=None)
    VpcSecurityGroupIds = attrib(default=None)


@attrs(**ATTRSCONFIG)
class DBCluster(Resource):
    """A Db Cluster for RDS.

    See Also:
        `AWS Cloud Formation documentation for DBCluster
        <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-rds-dbcluster.html>`_
    """

    RESOURCE_TYPE = "AWS::RDS::DBCluster"

    Properties: DBClusterProperties = attrib(
        factory=DBClusterProperties,
        converter=create_object_converter(DBClusterProperties),
    )


@attrs(**ATTRSCONFIG)
class DBClusterParameterGroupProperties(ResourceProperties):
    Description = attrib(default=None)
    Family = attrib(default=None)
    Parameters = attrib(default=None)
    Tags = attrib(default=None)


@attrs(**ATTRSCONFIG)
class DBClusterParameterGroup(Resource):
    """A Db Cluster Parameter Group for RDS.

    See Also:
        `AWS Cloud Formation documentation for DBClusterParameterGroup
        <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-rds-dbclusterparametergroup.html>`_
    """

    RESOURCE_TYPE = "AWS::RDS::DBClusterParameterGroup"

    Properties: DBClusterParameterGroupProperties = attrib(
        factory=DBClusterParameterGroupProperties,
        converter=create_object_converter(DBClusterParameterGroupProperties),
    )


@attrs(**ATTRSCONFIG)
class DBInstanceProperties(ResourceProperties):
    AllocatedStorage = attrib(default=None)
    AllowMajorVersionUpgrade = attrib(default=None)
    AutoMinorVersionUpgrade = attrib(default=None)
    AvailabilityZone = attrib(default=None)
    BackupRetentionPeriod = attrib(default=None)
    CharacterSetName = attrib(default=None)
    CopyTagsToSnapshot = attrib(default=None)
    DBClusterIdentifier = attrib(default=None)
    DBInstanceClass = attrib(default=None)
    DBInstanceIdentifier = attrib(default=None)
    DBName = attrib(default=None)
    DBParameterGroupName = attrib(default=None)
    DBSecurityGroups = attrib(default=None)
    DBSnapshotIdentifier = attrib(default=None)
    DBSubnetGroupName = attrib(default=None)
    DeleteAutomatedBackups = attrib(default=None)
    DeletionProtection = attrib(default=None)
    Domain = attrib(default=None)
    DomainIAMRoleName = attrib(default=None)
    EnableCloudwatchLogsExports = attrib(default=None)
    EnableIAMDatabaseAuthentication = attrib(default=None)
    EnablePerformanceInsights = attrib(default=None)
    Engine = attrib(default=None)
    EngineVersion = attrib(default=None)
    Iops = attrib(default=None)
    KmsKeyId = attrib(default=None)
    LicenseModel = attrib(default=None)
    MasterUsername = attrib(default=None)
    MasterUserPassword = attrib(default=None)
    MonitoringInterval = attrib(default=None)
    MonitoringRoleArn = attrib(default=None)
    MultiAZ = attrib(default=None)
    OptionGroupName = attrib(default=None)
    PerformanceInsightsKMSKeyId = attrib(default=None)
    PerformanceInsightsRetentionPeriod = attrib(default=None)
    Port = attrib(default=None)
    PreferredBackupWindow = attrib(default=None)
    PreferredMaintenanceWindow = attrib(default=None)
    ProcessorFeatures = attrib(default=None)
    PromotionTier = attrib(default=None)
    PubliclyAccessible = attrib(default=None)
    SourceDBInstanceIdentifier = attrib(default=None)
    SourceRegion = attrib(default=None)
    StorageEncrypted = attrib(default=None)
    StorageType = attrib(default=None)
    Tags = attrib(default=None)
    Timezone = attrib(default=None)
    UseDefaultProcessorFeatures = attrib(default=None)
    VPCSecurityGroups = attrib(default=None)


@attrs(**ATTRSCONFIG)
class DBInstance(Resource):
    """A Db Instance for RDS.

    See Also:
        `AWS Cloud Formation documentation for DBInstance
        <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-rds-database-instance.html>`_
    """

    RESOURCE_TYPE = "AWS::RDS::DBInstance"

    Properties: DBInstanceProperties = attrib(
        factory=DBInstanceProperties,
        converter=create_object_converter(DBInstanceProperties),
    )


@attrs(**ATTRSCONFIG)
class DBParameterGroupProperties(ResourceProperties):
    Description = attrib(default=None)
    Family = attrib(default=None)
    Parameters = attrib(default=None)
    Tags = attrib(default=None)


@attrs(**ATTRSCONFIG)
class DBParameterGroup(Resource):
    """A Db Parameter Group for RDS.

    See Also:
        `AWS Cloud Formation documentation for DBParameterGroup
        <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-rds-dbparametergroup.html>`_
    """

    RESOURCE_TYPE = "AWS::RDS::DBParameterGroup"

    Properties: DBParameterGroupProperties = attrib(
        factory=DBParameterGroupProperties,
        converter=create_object_converter(DBParameterGroupProperties),
    )


@attrs(**ATTRSCONFIG)
class DBSecurityGroupProperties(ResourceProperties):
    DBSecurityGroupIngress = attrib(default=None)
    EC2VpcId = attrib(default=None)
    GroupDescription = attrib(default=None)
    Tags = attrib(default=None)


@attrs(**ATTRSCONFIG)
class DBSecurityGroup(Resource):
    """A Db Security Group for RDS.

    See Also:
        `AWS Cloud Formation documentation for DBSecurityGroup
        <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-rds-security-group.html>`_
    """

    RESOURCE_TYPE = "AWS::RDS::DBSecurityGroup"

    Properties: DBSecurityGroupProperties = attrib(
        factory=DBSecurityGroupProperties,
        converter=create_object_converter(DBSecurityGroupProperties),
    )


@attrs(**ATTRSCONFIG)
class DBSecurityGroupIngressProperties(ResourceProperties):
    CIDRIP = attrib(default=None)
    DBSecurityGroupName = attrib(default=None)
    EC2SecurityGroupId = attrib(default=None)
    EC2SecurityGroupName = attrib(default=None)
    EC2SecurityGroupOwnerId = attrib(default=None)


@attrs(**ATTRSCONFIG)
class DBSecurityGroupIngress(Resource):
    """A Db Security Group Ingress for RDS.

    See Also:
        `AWS Cloud Formation documentation for DBSecurityGroupIngress
        <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-rds-security-group-ingress.html>`_
    """

    RESOURCE_TYPE = "AWS::RDS::DBSecurityGroupIngress"

    Properties: DBSecurityGroupIngressProperties = attrib(
        factory=DBSecurityGroupIngressProperties,
        converter=create_object_converter(DBSecurityGroupIngressProperties),
    )


@attrs(**ATTRSCONFIG)
class DBSubnetGroupProperties(ResourceProperties):
    DBSubnetGroupDescription = attrib(default=None)
    DBSubnetGroupName = attrib(default=None)
    SubnetIds = attrib(default=None)
    Tags = attrib(default=None)


@attrs(**ATTRSCONFIG)
class DBSubnetGroup(Resource):
    """A Db Subnet Group for RDS.

    See Also:
        `AWS Cloud Formation documentation for DBSubnetGroup
        <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-rds-dbsubnet-group.html>`_
    """

    RESOURCE_TYPE = "AWS::RDS::DBSubnetGroup"

    Properties: DBSubnetGroupProperties = attrib(
        factory=DBSubnetGroupProperties,
        converter=create_object_converter(DBSubnetGroupProperties),
    )


@attrs(**ATTRSCONFIG)
class EventSubscriptionProperties(ResourceProperties):
    Enabled = attrib(default=None)
    EventCategories = attrib(default=None)
    SnsTopicArn = attrib(default=None)
    SourceIds = attrib(default=None)
    SourceType = attrib(default=None)


@attrs(**ATTRSCONFIG)
class EventSubscription(Resource):
    """A Event Subscription for RDS.

    See Also:
        `AWS Cloud Formation documentation for EventSubscription
        <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-rds-eventsubscription.html>`_
    """

    RESOURCE_TYPE = "AWS::RDS::EventSubscription"

    Properties: EventSubscriptionProperties = attrib(
        factory=EventSubscriptionProperties,
        converter=create_object_converter(EventSubscriptionProperties),
    )


@attrs(**ATTRSCONFIG)
class OptionGroupProperties(ResourceProperties):
    EngineName = attrib(default=None)
    MajorEngineVersion = attrib(default=None)
    OptionConfigurations = attrib(default=None)
    OptionGroupDescription = attrib(default=None)
    Tags = attrib(default=None)


@attrs(**ATTRSCONFIG)
class OptionGroup(Resource):
    """A Option Group for RDS.

    See Also:
        `AWS Cloud Formation documentation for OptionGroup
        <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-rds-optiongroup.html>`_
    """

    RESOURCE_TYPE = "AWS::RDS::OptionGroup"

    Properties: OptionGroupProperties = attrib(
        factory=OptionGroupProperties,
        converter=create_object_converter(OptionGroupProperties),
    )
