PHP WebShell

Текущая директория: /opt/BitGoJS/node_modules/@babylonlabs-io/babylon-proto-ts/dist/generated/babylon/epoching/v1

Просмотр файла: epoching.d.ts

import { BinaryReader, BinaryWriter } from "@bufbuild/protobuf/wire";
import { Coin } from "../../../cosmos/base/v1beta1/coin";
import { MsgBeginRedelegate, MsgCancelUnbondingDelegation, MsgCreateValidator, MsgDelegate, MsgEditValidator, MsgUndelegate, MsgUpdateParams } from "../../../cosmos/staking/v1beta1/tx";
export declare const protobufPackage = "babylon.epoching.v1";
/** BondState is the bond state of a validator or delegation */
export declare enum BondState {
    /** CREATED - CREATED is when the validator/delegation has been created */
    CREATED = 0,
    /** BONDED - CREATED is when the validator/delegation has become bonded */
    BONDED = 1,
    /** UNBONDING - CREATED is when the validator/delegation has become unbonding */
    UNBONDING = 2,
    /** UNBONDED - CREATED is when the validator/delegation has become unbonded */
    UNBONDED = 3,
    /** REMOVED - CREATED is when the validator/delegation has been removed */
    REMOVED = 4,
    UNRECOGNIZED = -1
}
export declare function bondStateFromJSON(object: any): BondState;
export declare function bondStateToJSON(object: BondState): string;
/** Epoch is a structure that contains the metadata of an epoch */
export interface Epoch {
    /** epoch_number is the number of this epoch */
    epochNumber: number;
    /** current_epoch_interval is the epoch interval at the time of this epoch */
    currentEpochInterval: number;
    /** first_block_height is the height of the first block in this epoch */
    firstBlockHeight: number;
    /**
     * last_block_time is the time of the last block in this epoch.
     * Babylon needs to remember the last header's time of each epoch to complete
     * unbonding validators/delegations when a previous epoch's checkpoint is
     * finalised. The last_block_time field is nil in the epoch's beginning, and
     * is set upon the end of this epoch.
     */
    lastBlockTime: Date | undefined;
    /**
     * sealer is the last block of the sealed epoch
     * sealer_app_hash points to the sealer but stored in the 1st header
     * of the next epoch
     */
    sealerAppHash: Uint8Array;
    /**
     * sealer_block_hash is the hash of the sealer
     * the validator set has generated a BLS multisig on the hash,
     * i.e., hash of the last block in the epoch
     */
    sealerBlockHash: Uint8Array;
}
/**
 * QueuedMessage is a message that can change the validator set and is delayed
 * to the end of an epoch
 */
export interface QueuedMessage {
    /** tx_id is the ID of the tx that contains the message */
    txId: Uint8Array;
    /** msg_id is the original message ID, i.e., hash of the marshaled message */
    msgId: Uint8Array;
    /** block_height is the height when this msg is submitted to Babylon */
    blockHeight: number;
    /** block_time is the timestamp when this msg is submitted to Babylon */
    blockTime: Date | undefined;
    msgCreateValidator?: MsgCreateValidator | undefined;
    msgDelegate?: MsgDelegate | undefined;
    msgUndelegate?: MsgUndelegate | undefined;
    msgBeginRedelegate?: MsgBeginRedelegate | undefined;
    msgCancelUnbondingDelegation?: MsgCancelUnbondingDelegation | undefined;
    msgEditValidator?: MsgEditValidator | undefined;
    msgUpdateParams?: MsgUpdateParams | undefined;
}
/** ValStateUpdate is a message that records a state update of a validator */
export interface ValStateUpdate {
    state: BondState;
    blockHeight: number;
    blockTime: Date | undefined;
}
/**
 * ValidatorLifecycle is a message that records the lifecycle of
 * a validator
 */
export interface ValidatorLifecycle {
    valAddr: string;
    valLife: ValStateUpdate[];
}
/**
 * DelegationStateUpdate is the message that records a state update of a
 * delegation
 */
export interface DelegationStateUpdate {
    state: BondState;
    valAddr: string;
    amount: Coin | undefined;
    blockHeight: number;
    blockTime: Date | undefined;
}
/**
 * ValidatorLifecycle is a message that records the lifecycle of
 * a delegation
 */
export interface DelegationLifecycle {
    delAddr: string;
    delLife: DelegationStateUpdate[];
}
/** Validator is a message that denotes a validator */
export interface Validator {
    /** addr is the validator's address (in sdk.ValAddress) */
    addr: Uint8Array;
    /** power is the validator's voting power */
    power: number;
}
export declare const Epoch: MessageFns<Epoch>;
export declare const QueuedMessage: MessageFns<QueuedMessage>;
export declare const ValStateUpdate: MessageFns<ValStateUpdate>;
export declare const ValidatorLifecycle: MessageFns<ValidatorLifecycle>;
export declare const DelegationStateUpdate: MessageFns<DelegationStateUpdate>;
export declare const DelegationLifecycle: MessageFns<DelegationLifecycle>;
export declare const Validator: MessageFns<Validator>;
type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
export type DeepPartial<T> = T extends Builtin ? T : T extends globalThis.Array<infer U> ? globalThis.Array<DeepPartial<U>> : T extends ReadonlyArray<infer U> ? ReadonlyArray<DeepPartial<U>> : T extends {} ? {
    [K in keyof T]?: DeepPartial<T[K]>;
} : Partial<T>;
type KeysOfUnion<T> = T extends T ? keyof T : never;
export type Exact<P, I extends P> = P extends Builtin ? P : P & {
    [K in keyof P]: Exact<P[K], I[K]>;
} & {
    [K in Exclude<keyof I, KeysOfUnion<P>>]: never;
};
export interface MessageFns<T> {
    encode(message: T, writer?: BinaryWriter): BinaryWriter;
    decode(input: BinaryReader | Uint8Array, length?: number): T;
    fromJSON(object: any): T;
    toJSON(message: T): unknown;
    create<I extends Exact<DeepPartial<T>, I>>(base?: I): T;
    fromPartial<I extends Exact<DeepPartial<T>, I>>(object: I): T;
}
export {};
//# sourceMappingURL=epoching.d.ts.map

Выполнить команду


Для локальной разработки. Не используйте в интернете!