"""
@generated by mypy-protobuf.  Do not edit manually!
isort:skip_file
"""

import builtins
import google.protobuf.descriptor
import google.protobuf.internal.enum_type_wrapper
import google.protobuf.message
import google.protobuf.timestamp_pb2
import sys
import typing

if sys.version_info >= (3, 10):
    import typing as typing_extensions
else:
    import typing_extensions

DESCRIPTOR: google.protobuf.descriptor.FileDescriptor

@typing.final
class Backup(google.protobuf.message.Message):
    """An object that represents MySQL backup.

    See [the documentation](/docs/managed-mysql/concepts/backup) for details.
    """

    DESCRIPTOR: google.protobuf.descriptor.Descriptor

    class _BackupCreationType:
        ValueType = typing.NewType("ValueType", builtins.int)
        V: typing_extensions.TypeAlias = ValueType

    class _BackupCreationTypeEnumTypeWrapper(google.protobuf.internal.enum_type_wrapper._EnumTypeWrapper[Backup._BackupCreationType.ValueType], builtins.type):
        DESCRIPTOR: google.protobuf.descriptor.EnumDescriptor
        BACKUP_CREATION_TYPE_UNSPECIFIED: Backup._BackupCreationType.ValueType  # 0
        AUTOMATED: Backup._BackupCreationType.ValueType  # 1
        """Backup created by automated daily schedule"""
        MANUAL: Backup._BackupCreationType.ValueType  # 2
        """Backup created by user request"""

    class BackupCreationType(_BackupCreationType, metaclass=_BackupCreationTypeEnumTypeWrapper): ...
    BACKUP_CREATION_TYPE_UNSPECIFIED: Backup.BackupCreationType.ValueType  # 0
    AUTOMATED: Backup.BackupCreationType.ValueType  # 1
    """Backup created by automated daily schedule"""
    MANUAL: Backup.BackupCreationType.ValueType  # 2
    """Backup created by user request"""

    class _BackupStatus:
        ValueType = typing.NewType("ValueType", builtins.int)
        V: typing_extensions.TypeAlias = ValueType

    class _BackupStatusEnumTypeWrapper(google.protobuf.internal.enum_type_wrapper._EnumTypeWrapper[Backup._BackupStatus.ValueType], builtins.type):
        DESCRIPTOR: google.protobuf.descriptor.EnumDescriptor
        BACKUP_STATUS_UNSPECIFIED: Backup._BackupStatus.ValueType  # 0
        DONE: Backup._BackupStatus.ValueType  # 1
        """Backup is done"""
        CREATING: Backup._BackupStatus.ValueType  # 2
        """Backup is creating"""

    class BackupStatus(_BackupStatus, metaclass=_BackupStatusEnumTypeWrapper): ...
    BACKUP_STATUS_UNSPECIFIED: Backup.BackupStatus.ValueType  # 0
    DONE: Backup.BackupStatus.ValueType  # 1
    """Backup is done"""
    CREATING: Backup.BackupStatus.ValueType  # 2
    """Backup is creating"""

    ID_FIELD_NUMBER: builtins.int
    FOLDER_ID_FIELD_NUMBER: builtins.int
    CREATED_AT_FIELD_NUMBER: builtins.int
    SOURCE_CLUSTER_ID_FIELD_NUMBER: builtins.int
    STARTED_AT_FIELD_NUMBER: builtins.int
    SIZE_FIELD_NUMBER: builtins.int
    TYPE_FIELD_NUMBER: builtins.int
    STATUS_FIELD_NUMBER: builtins.int
    JOURNAL_SIZE_FIELD_NUMBER: builtins.int
    id: builtins.str
    """ID of the backup."""
    folder_id: builtins.str
    """ID of the folder that the backup belongs to."""
    source_cluster_id: builtins.str
    """ID of the cluster that the backup was created for."""
    size: builtins.int
    """Size of backup, in bytes"""
    type: global___Backup.BackupCreationType.ValueType
    """How this backup was created (manual/automatic/etc...)"""
    status: global___Backup.BackupStatus.ValueType
    """Status of backup"""
    journal_size: builtins.int
    """Size of the journal associated with backup, in bytes."""
    @property
    def created_at(self) -> google.protobuf.timestamp_pb2.Timestamp:
        """Creation timestamp (the time when the backup operation was completed)."""

    @property
    def started_at(self) -> google.protobuf.timestamp_pb2.Timestamp:
        """Start timestamp (the time when the backup operation was started)."""

    def __init__(
        self,
        *,
        id: builtins.str = ...,
        folder_id: builtins.str = ...,
        created_at: google.protobuf.timestamp_pb2.Timestamp | None = ...,
        source_cluster_id: builtins.str = ...,
        started_at: google.protobuf.timestamp_pb2.Timestamp | None = ...,
        size: builtins.int = ...,
        type: global___Backup.BackupCreationType.ValueType = ...,
        status: global___Backup.BackupStatus.ValueType = ...,
        journal_size: builtins.int = ...,
    ) -> None: ...
    def HasField(self, field_name: typing.Literal["created_at", b"created_at", "started_at", b"started_at"]) -> builtins.bool: ...
    def ClearField(self, field_name: typing.Literal["created_at", b"created_at", "folder_id", b"folder_id", "id", b"id", "journal_size", b"journal_size", "size", b"size", "source_cluster_id", b"source_cluster_id", "started_at", b"started_at", "status", b"status", "type", b"type"]) -> None: ...

global___Backup = Backup
