import { BinaryReader, BinaryWriter } from "../../../binary"; /** TableDescriptor describes an ORM table. */ export interface TableDescriptor { /** primary_key defines the primary key for the table. */ primaryKey?: PrimaryKeyDescriptor | undefined; /** index defines one or more secondary indexes. */ index: SecondaryIndexDescriptor[]; /** * id is a non-zero integer ID that must be unique within the * tables and singletons in this file. It may be deprecated in the future when this * can be auto-generated. */ id: number; } export interface TableDescriptorProtoMsg { typeUrl: "/cosmos.orm.v1.TableDescriptor"; value: Uint8Array; } /** TableDescriptor describes an ORM table. */ export interface TableDescriptorAmino { /** primary_key defines the primary key for the table. */ primary_key?: PrimaryKeyDescriptorAmino | undefined; /** index defines one or more secondary indexes. */ index?: SecondaryIndexDescriptorAmino[]; /** * id is a non-zero integer ID that must be unique within the * tables and singletons in this file. It may be deprecated in the future when this * can be auto-generated. */ id?: number; } export interface TableDescriptorAminoMsg { type: "cosmos-sdk/TableDescriptor"; value: TableDescriptorAmino; } /** TableDescriptor describes an ORM table. */ export interface TableDescriptorSDKType { primary_key?: PrimaryKeyDescriptorSDKType | undefined; index: SecondaryIndexDescriptorSDKType[]; id: number; } /** PrimaryKeyDescriptor describes a table primary key. */ export interface PrimaryKeyDescriptor { /** * fields is a comma-separated list of fields in the primary key. Spaces are * not allowed. Supported field types, their encodings, and any applicable constraints * are described below. * - uint32 are encoded as 2,3,4 or 5 bytes using a compact encoding that * is suitable for sorted iteration (not varint encoding). This type is * well-suited for small integers. * - uint64 are encoded as 2,4,6 or 9 bytes using a compact encoding that * is suitable for sorted iteration (not varint encoding). This type is * well-suited for small integers such as auto-incrementing sequences. * - fixed32, fixed64 are encoded as big-endian fixed width bytes and support * sorted iteration. These types are well-suited for encoding fixed with * decimals as integers. * - string's are encoded as raw bytes in terminal key segments and null-terminated * in non-terminal segments. Null characters are thus forbidden in strings. * string fields support sorted iteration. * - bytes are encoded as raw bytes in terminal segments and length-prefixed * with a 32-bit unsigned varint in non-terminal segments. * - int32, sint32, int64, sint64, sfixed32, sfixed64 are encoded as fixed width bytes with * an encoding that enables sorted iteration. * - google.protobuf.Timestamp and google.protobuf.Duration are encoded * as 12 bytes using an encoding that enables sorted iteration. * - enum fields are encoded using varint encoding and do not support sorted * iteration. * - bool fields are encoded as a single byte 0 or 1. * * All other fields types are unsupported in keys including repeated and * oneof fields. * * Primary keys are prefixed by the varint encoded table id and the byte 0x0 * plus any additional prefix specified by the schema. */ fields: string; /** * auto_increment specifies that the primary key is generated by an * auto-incrementing integer. If this is set to true fields must only * contain one field of that is of type uint64. */ autoIncrement: boolean; } export interface PrimaryKeyDescriptorProtoMsg { typeUrl: "/cosmos.orm.v1.PrimaryKeyDescriptor"; value: Uint8Array; } /** PrimaryKeyDescriptor describes a table primary key. */ export interface PrimaryKeyDescriptorAmino { /** * fields is a comma-separated list of fields in the primary key. Spaces are * not allowed. Supported field types, their encodings, and any applicable constraints * are described below. * - uint32 are encoded as 2,3,4 or 5 bytes using a compact encoding that * is suitable for sorted iteration (not varint encoding). This type is * well-suited for small integers. * - uint64 are encoded as 2,4,6 or 9 bytes using a compact encoding that * is suitable for sorted iteration (not varint encoding). This type is * well-suited for small integers such as auto-incrementing sequences. * - fixed32, fixed64 are encoded as big-endian fixed width bytes and support * sorted iteration. These types are well-suited for encoding fixed with * decimals as integers. * - string's are encoded as raw bytes in terminal key segments and null-terminated * in non-terminal segments. Null characters are thus forbidden in strings. * string fields support sorted iteration. * - bytes are encoded as raw bytes in terminal segments and length-prefixed * with a 32-bit unsigned varint in non-terminal segments. * - int32, sint32, int64, sint64, sfixed32, sfixed64 are encoded as fixed width bytes with * an encoding that enables sorted iteration. * - google.protobuf.Timestamp and google.protobuf.Duration are encoded * as 12 bytes using an encoding that enables sorted iteration. * - enum fields are encoded using varint encoding and do not support sorted * iteration. * - bool fields are encoded as a single byte 0 or 1. * * All other fields types are unsupported in keys including repeated and * oneof fields. * * Primary keys are prefixed by the varint encoded table id and the byte 0x0 * plus any additional prefix specified by the schema. */ fields?: string; /** * auto_increment specifies that the primary key is generated by an * auto-incrementing integer. If this is set to true fields must only * contain one field of that is of type uint64. */ auto_increment?: boolean; } export interface PrimaryKeyDescriptorAminoMsg { type: "cosmos-sdk/PrimaryKeyDescriptor"; value: PrimaryKeyDescriptorAmino; } /** PrimaryKeyDescriptor describes a table primary key. */ export interface PrimaryKeyDescriptorSDKType { fields: string; auto_increment: boolean; } /** PrimaryKeyDescriptor describes a table secondary index. */ export interface SecondaryIndexDescriptor { /** * fields is a comma-separated list of fields in the index. The supported * field types are the same as those for PrimaryKeyDescriptor.fields. * Index keys are prefixed by the varint encoded table id and the varint * encoded index id plus any additional prefix specified by the schema. * * In addition the the field segments, non-unique index keys are suffixed with * any additional primary key fields not present in the index fields so that the * primary key can be reconstructed. Unique indexes instead of being suffixed * store the remaining primary key fields in the value.. */ fields: string; /** * id is a non-zero integer ID that must be unique within the indexes for this * table and less than 32768. It may be deprecated in the future when this can * be auto-generated. */ id: number; /** unique specifies that this an unique index. */ unique: boolean; } export interface SecondaryIndexDescriptorProtoMsg { typeUrl: "/cosmos.orm.v1.SecondaryIndexDescriptor"; value: Uint8Array; } /** PrimaryKeyDescriptor describes a table secondary index. */ export interface SecondaryIndexDescriptorAmino { /** * fields is a comma-separated list of fields in the index. The supported * field types are the same as those for PrimaryKeyDescriptor.fields. * Index keys are prefixed by the varint encoded table id and the varint * encoded index id plus any additional prefix specified by the schema. * * In addition the the field segments, non-unique index keys are suffixed with * any additional primary key fields not present in the index fields so that the * primary key can be reconstructed. Unique indexes instead of being suffixed * store the remaining primary key fields in the value.. */ fields?: string; /** * id is a non-zero integer ID that must be unique within the indexes for this * table and less than 32768. It may be deprecated in the future when this can * be auto-generated. */ id?: number; /** unique specifies that this an unique index. */ unique?: boolean; } export interface SecondaryIndexDescriptorAminoMsg { type: "cosmos-sdk/SecondaryIndexDescriptor"; value: SecondaryIndexDescriptorAmino; } /** PrimaryKeyDescriptor describes a table secondary index. */ export interface SecondaryIndexDescriptorSDKType { fields: string; id: number; unique: boolean; } /** TableDescriptor describes an ORM singleton table which has at most one instance. */ export interface SingletonDescriptor { /** * id is a non-zero integer ID that must be unique within the * tables and singletons in this file. It may be deprecated in the future when this * can be auto-generated. */ id: number; } export interface SingletonDescriptorProtoMsg { typeUrl: "/cosmos.orm.v1.SingletonDescriptor"; value: Uint8Array; } /** TableDescriptor describes an ORM singleton table which has at most one instance. */ export interface SingletonDescriptorAmino { /** * id is a non-zero integer ID that must be unique within the * tables and singletons in this file. It may be deprecated in the future when this * can be auto-generated. */ id?: number; } export interface SingletonDescriptorAminoMsg { type: "cosmos-sdk/SingletonDescriptor"; value: SingletonDescriptorAmino; } /** TableDescriptor describes an ORM singleton table which has at most one instance. */ export interface SingletonDescriptorSDKType { id: number; } export declare const TableDescriptor: { typeUrl: string; aminoType: string; encode(message: TableDescriptor, writer?: BinaryWriter): BinaryWriter; decode(input: BinaryReader | Uint8Array, length?: number): TableDescriptor; fromPartial(object: Partial): TableDescriptor; fromAmino(object: TableDescriptorAmino): TableDescriptor; toAmino(message: TableDescriptor): TableDescriptorAmino; fromAminoMsg(object: TableDescriptorAminoMsg): TableDescriptor; toAminoMsg(message: TableDescriptor): TableDescriptorAminoMsg; fromProtoMsg(message: TableDescriptorProtoMsg): TableDescriptor; toProto(message: TableDescriptor): Uint8Array; toProtoMsg(message: TableDescriptor): TableDescriptorProtoMsg; }; export declare const PrimaryKeyDescriptor: { typeUrl: string; aminoType: string; encode(message: PrimaryKeyDescriptor, writer?: BinaryWriter): BinaryWriter; decode(input: BinaryReader | Uint8Array, length?: number): PrimaryKeyDescriptor; fromPartial(object: Partial): PrimaryKeyDescriptor; fromAmino(object: PrimaryKeyDescriptorAmino): PrimaryKeyDescriptor; toAmino(message: PrimaryKeyDescriptor): PrimaryKeyDescriptorAmino; fromAminoMsg(object: PrimaryKeyDescriptorAminoMsg): PrimaryKeyDescriptor; toAminoMsg(message: PrimaryKeyDescriptor): PrimaryKeyDescriptorAminoMsg; fromProtoMsg(message: PrimaryKeyDescriptorProtoMsg): PrimaryKeyDescriptor; toProto(message: PrimaryKeyDescriptor): Uint8Array; toProtoMsg(message: PrimaryKeyDescriptor): PrimaryKeyDescriptorProtoMsg; }; export declare const SecondaryIndexDescriptor: { typeUrl: string; aminoType: string; encode(message: SecondaryIndexDescriptor, writer?: BinaryWriter): BinaryWriter; decode(input: BinaryReader | Uint8Array, length?: number): SecondaryIndexDescriptor; fromPartial(object: Partial): SecondaryIndexDescriptor; fromAmino(object: SecondaryIndexDescriptorAmino): SecondaryIndexDescriptor; toAmino(message: SecondaryIndexDescriptor): SecondaryIndexDescriptorAmino; fromAminoMsg(object: SecondaryIndexDescriptorAminoMsg): SecondaryIndexDescriptor; toAminoMsg(message: SecondaryIndexDescriptor): SecondaryIndexDescriptorAminoMsg; fromProtoMsg(message: SecondaryIndexDescriptorProtoMsg): SecondaryIndexDescriptor; toProto(message: SecondaryIndexDescriptor): Uint8Array; toProtoMsg(message: SecondaryIndexDescriptor): SecondaryIndexDescriptorProtoMsg; }; export declare const SingletonDescriptor: { typeUrl: string; aminoType: string; encode(message: SingletonDescriptor, writer?: BinaryWriter): BinaryWriter; decode(input: BinaryReader | Uint8Array, length?: number): SingletonDescriptor; fromPartial(object: Partial): SingletonDescriptor; fromAmino(object: SingletonDescriptorAmino): SingletonDescriptor; toAmino(message: SingletonDescriptor): SingletonDescriptorAmino; fromAminoMsg(object: SingletonDescriptorAminoMsg): SingletonDescriptor; toAminoMsg(message: SingletonDescriptor): SingletonDescriptorAminoMsg; fromProtoMsg(message: SingletonDescriptorProtoMsg): SingletonDescriptor; toProto(message: SingletonDescriptor): Uint8Array; toProtoMsg(message: SingletonDescriptor): SingletonDescriptorProtoMsg; };