"""
@generated by mypy-protobuf.  Do not edit manually!
isort:skip_file
"""
import builtins
import collections.abc
import google.protobuf.descriptor
import google.protobuf.descriptor_pb2
import google.protobuf.internal.containers
import google.protobuf.internal.enum_type_wrapper
import google.protobuf.internal.extension_dict
import google.protobuf.message
import sys
import typing

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

DESCRIPTOR: google.protobuf.descriptor.FileDescriptor

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

class _StorageTypeEnumTypeWrapper(google.protobuf.internal.enum_type_wrapper._EnumTypeWrapper[_StorageType.ValueType], builtins.type):
    DESCRIPTOR: google.protobuf.descriptor.EnumDescriptor
    STORAGE_TYPE_DEFAULT_UNSPECIFIED: _StorageType.ValueType  # 0
    """STORAGE_TYPE_DEFAULT_UNSPECIFIED indicates the persistent
    KV-storage where primary key entries are stored in merkle-tree
    backed commitment storage and indexes and seqs are stored in
    fast index storage. Note that the Cosmos SDK before store/v2alpha1
    does not support this.
    """
    STORAGE_TYPE_MEMORY: _StorageType.ValueType  # 1
    """STORAGE_TYPE_MEMORY indicates in-memory storage that will be
    reloaded every time an app restarts. Tables with this type of storage
    will by default be ignored when importing and exporting a module's
    state from JSON.
    """
    STORAGE_TYPE_TRANSIENT: _StorageType.ValueType  # 2
    """STORAGE_TYPE_TRANSIENT indicates transient storage that is reset
    at the end of every block. Tables with this type of storage
    will by default be ignored when importing and exporting a module's
    state from JSON.
    """
    STORAGE_TYPE_INDEX: _StorageType.ValueType  # 3
    """STORAGE_TYPE_INDEX indicates persistent storage which is not backed
    by a merkle-tree and won't affect the app hash. Note that the Cosmos SDK
    before store/v2alpha1 does not support this.
    """
    STORAGE_TYPE_COMMITMENT: _StorageType.ValueType  # 4
    """STORAGE_TYPE_INDEX indicates persistent storage which is backed by
    a merkle-tree. With this type of storage, both primary and index keys
    will affect the app hash and this is generally less efficient
    than using STORAGE_TYPE_DEFAULT_UNSPECIFIED which separates index
    keys into index storage. Note that modules built with the
    Cosmos SDK before store/v2alpha1 must specify STORAGE_TYPE_COMMITMENT
    instead of STORAGE_TYPE_DEFAULT_UNSPECIFIED or STORAGE_TYPE_INDEX
    because this is the only type of persistent storage available.
    """

class StorageType(_StorageType, metaclass=_StorageTypeEnumTypeWrapper):
    """StorageType"""

STORAGE_TYPE_DEFAULT_UNSPECIFIED: StorageType.ValueType  # 0
"""STORAGE_TYPE_DEFAULT_UNSPECIFIED indicates the persistent
KV-storage where primary key entries are stored in merkle-tree
backed commitment storage and indexes and seqs are stored in
fast index storage. Note that the Cosmos SDK before store/v2alpha1
does not support this.
"""
STORAGE_TYPE_MEMORY: StorageType.ValueType  # 1
"""STORAGE_TYPE_MEMORY indicates in-memory storage that will be
reloaded every time an app restarts. Tables with this type of storage
will by default be ignored when importing and exporting a module's
state from JSON.
"""
STORAGE_TYPE_TRANSIENT: StorageType.ValueType  # 2
"""STORAGE_TYPE_TRANSIENT indicates transient storage that is reset
at the end of every block. Tables with this type of storage
will by default be ignored when importing and exporting a module's
state from JSON.
"""
STORAGE_TYPE_INDEX: StorageType.ValueType  # 3
"""STORAGE_TYPE_INDEX indicates persistent storage which is not backed
by a merkle-tree and won't affect the app hash. Note that the Cosmos SDK
before store/v2alpha1 does not support this.
"""
STORAGE_TYPE_COMMITMENT: StorageType.ValueType  # 4
"""STORAGE_TYPE_INDEX indicates persistent storage which is backed by
a merkle-tree. With this type of storage, both primary and index keys
will affect the app hash and this is generally less efficient
than using STORAGE_TYPE_DEFAULT_UNSPECIFIED which separates index
keys into index storage. Note that modules built with the
Cosmos SDK before store/v2alpha1 must specify STORAGE_TYPE_COMMITMENT
instead of STORAGE_TYPE_DEFAULT_UNSPECIFIED or STORAGE_TYPE_INDEX
because this is the only type of persistent storage available.
"""
global___StorageType = StorageType

@typing_extensions.final
class ModuleSchemaDescriptor(google.protobuf.message.Message):
    """ModuleSchemaDescriptor describe's a module's ORM schema."""

    DESCRIPTOR: google.protobuf.descriptor.Descriptor

    @typing_extensions.final
    class FileEntry(google.protobuf.message.Message):
        """FileEntry describes an ORM file used in a module."""

        DESCRIPTOR: google.protobuf.descriptor.Descriptor

        ID_FIELD_NUMBER: builtins.int
        PROTO_FILE_NAME_FIELD_NUMBER: builtins.int
        STORAGE_TYPE_FIELD_NUMBER: builtins.int
        id: builtins.int
        """id is a prefix that will be varint encoded and prepended to all the
        table keys specified in the file's tables.
        """
        proto_file_name: builtins.str
        """proto_file_name is the name of a file .proto in that contains
        table definitions. The .proto file must be in a package that the
        module has referenced using cosmos.app.v1.ModuleDescriptor.use_package.
        """
        storage_type: global___StorageType.ValueType
        """storage_type optionally indicates the type of storage this file's
        tables should used. If it is left unspecified, the default KV-storage
        of the app will be used.
        """
        def __init__(
            self,
            *,
            id: builtins.int = ...,
            proto_file_name: builtins.str = ...,
            storage_type: global___StorageType.ValueType = ...,
        ) -> None: ...
        def ClearField(self, field_name: typing_extensions.Literal["id", b"id", "proto_file_name", b"proto_file_name", "storage_type", b"storage_type"]) -> None: ...

    SCHEMA_FILE_FIELD_NUMBER: builtins.int
    PREFIX_FIELD_NUMBER: builtins.int
    @property
    def schema_file(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___ModuleSchemaDescriptor.FileEntry]: ...
    prefix: builtins.bytes
    """prefix is an optional prefix that precedes all keys in this module's
    store.
    """
    def __init__(
        self,
        *,
        schema_file: collections.abc.Iterable[global___ModuleSchemaDescriptor.FileEntry] | None = ...,
        prefix: builtins.bytes = ...,
    ) -> None: ...
    def ClearField(self, field_name: typing_extensions.Literal["prefix", b"prefix", "schema_file", b"schema_file"]) -> None: ...

global___ModuleSchemaDescriptor = ModuleSchemaDescriptor

MODULE_SCHEMA_FIELD_NUMBER: builtins.int
module_schema: google.protobuf.internal.extension_dict._ExtensionFieldDescriptor[google.protobuf.descriptor_pb2.MessageOptions, global___ModuleSchemaDescriptor]
"""module_schema is used to define the ORM schema for an app module.
All module config messages that use module_schema must also declare
themselves as app module config messages using the cosmos.app.v1.is_module
option.
"""
