import { KVStore } from "@keplr-wallet/common"; import { ChainGetter } from "@keplr-wallet/stores"; import { PollingStatusSubscription } from "./polling-status-subscription"; import { IBCTransferHistory, IBCTransferHistoryStatus, UncommitedHistory } from "./types"; /** Stores IBC sending, pending, and failure transactions state for some time period. */ export declare class IBCTransferHistoryStore { protected readonly kvStore: KVStore; protected readonly chainGetter: ChainGetter; protected readonly keepHistoryDays: number; protected _uncommitedHistories: UncommitedHistory[]; protected _histories: IBCTransferHistory[]; protected onHistoryChangedHandlers: ((history: IBCTransferHistory) => void)[]; protected blockSubscriberMap: Map; constructor(kvStore: KVStore, chainGetter: ChainGetter, keepHistoryDays?: number); addHistoryChangedHandler(handler: (history: IBCTransferHistory) => void): void; get histories(): IBCTransferHistory[]; getHistoriesByAccount: (address: string) => IBCTransferHistory[]; getUncommitedHistoriesByAccount: (address: string) => UncommitedHistory[]; getHistoriesAndUncommitedHistoriesByAccount: (address: string) => (IBCTransferHistory | UncommitedHistory)[]; protected getBlockSubscriber(chainId: string): PollingStatusSubscription; protected traceTimeoutHeight(statusSubscriber: PollingStatusSubscription, timeoutHeight: string): { unsubscriber: () => void; promise: Promise; }; protected traceTimeoutTimestamp(statusSubscriber: PollingStatusSubscription, timeoutTimestamp: string): { unsubscriber: () => void; promise: Promise; }; protected traceHistoryStatus(history: Pick): Promise; pushUncommitedHistory(history: Omit): Generator, void, unknown>; pushPendingHistory(history: Omit): Generator, void, unknown>; removeUncommittedHistory(txHash: string): void; protected pushPendingHistoryWithCreatedAt(history: Omit): Generator, void, unknown>; protected traceUncommitedHistoryAndUpgradeToPendingHistory(txHash: string): Generator, void, any>; tryUpdateHistoryStatus(txHash: string): Generator | Promise, void, IBCTransferHistoryStatus>; protected get historyMapByTxHash(): Map; protected restore(): Generator | Generator, void, unknown>, void, string | undefined>; protected trimObsoleteHistory(): Generator, void, unknown>; protected save(): Promise; } export * from "./types";