UNPKG

@unilogin/sdk

Version:

SDK is a JS library, that communicates with relayer. SDK allows managing contract, by creating basic contract-calling messages.

21 lines 1.07 kB
import { BlockchainService } from '@unilogin/contracts'; import { WalletEventCallback, WalletEventFilter, WalletEventType } from '../models/events'; import { WalletEventsObserver } from './WalletEventsObserver'; import { BlockNumberState } from '../states/BlockNumberState'; import { IStorageService } from '../models/IStorageService'; declare class WalletEventsObserverFactory { private blockchainService; private currentBlock; protected observers: Record<string, WalletEventsObserver>; private unsubscribe; private blockNumberStorage; constructor(blockchainService: BlockchainService, currentBlock: BlockNumberState, storageService?: IStorageService); start(): Promise<void>; fetchEvents(): Promise<void>; fetchEventsOfTypes(types: WalletEventType[]): Promise<void>; subscribe(eventType: WalletEventType, filter: WalletEventFilter, callback: WalletEventCallback): () => void; stop(): void; finalizeAndStop(): void; } export default WalletEventsObserverFactory; //# sourceMappingURL=WalletEventsObserverFactory.d.ts.map