UNPKG

@broxus/js-bridge-essentials

Version:

Bridge JavaScript Essentials library

62 lines (61 loc) 3.89 kB
import { type Forceable, type Silentable, SmartContractModel, type Syncable, type Watchable } from '@broxus/js-core'; import { type Address, type DecodeEventParams, type DecodeTransactionParams, type ProviderRpcClient, type Subscriber, type Transaction } from 'everscale-inpage-provider'; import { type TvmEvmEventNativeAbi } from '../../models/tvm-evm-event-native/abi'; import { type TvmEvmEventNativeDecodedData, type TvmEvmEventNativeDecodedEvent, type TvmEvmEventNativeDecodedTransaction, type TvmEvmEventNativeDetails, TvmEvmEventNativeUtils } from '../../models/tvm-evm-event-native/TvmEvmEventNativeUtils'; export interface TvmEvmEventNativeCtorOptions { watchDebounceDelay?: number; } export interface TvmEvmEventNativeCreateOptions extends TvmEvmEventNativeCtorOptions, Syncable, Watchable { watchCallback?: VoidFunction; } export interface TvmEvmEventNativeData extends TvmEvmEventNativeDetails { decodedData: TvmEvmEventNativeDecodedData; } export declare class TvmEvmEventNative extends SmartContractModel<TvmEvmEventNativeData> { protected readonly _connection: ProviderRpcClient; protected readonly options?: Readonly<TvmEvmEventNativeCtorOptions> | undefined; protected readonly _provider?: ProviderRpcClient | undefined; static Utils: typeof TvmEvmEventNativeUtils; /** * @param {ProviderRpcClient} _connection Standalone RPC client that doesn't require connection * to the TVM wallet provider * @param {Address | string} address Native Event root address * @param {Readonly<TvmEvmEventNativeCtorOptions>} [options] (optional) Native Event ABI * Wrapper options * @param {ProviderRpcClient} [_provider] (optional) RPC provider that require connection to * the TVM wallet */ constructor(_connection: ProviderRpcClient, address: Address | string, options?: Readonly<TvmEvmEventNativeCtorOptions> | undefined, _provider?: ProviderRpcClient | undefined); /** * @param {ProviderRpcClient} connection Standalone RPC client that doesn't require connection * to the TVM wallet provider * @param {Address | string} address Native Event root address * @param {Readonly<TvmEvmEventNativeCreateOptions>} [options] (optional) Native Event ABI * Wrapper options * @param {ProviderRpcClient} [provider] (optional) RPC provider that require connection to the * TVM wallet */ static create(connection: ProviderRpcClient, address: Address | string, options?: TvmEvmEventNativeCreateOptions, provider?: ProviderRpcClient): Promise<TvmEvmEventNative>; sync(options?: Forceable & Silentable): Promise<void>; watch(callback?: VoidFunction): Promise<Subscriber>; unwatch(): Promise<void>; nonce(): Promise<string>; recipient(): Promise<string>; relayRound(): Promise<Address>; roundNumber(): Promise<number>; sender(): Promise<Address>; get balance(): TvmEvmEventNativeData['balance']; get confirms(): TvmEvmEventNativeData['confirms']; get decodedData(): TvmEvmEventNativeData['decodedData']; get empty(): TvmEvmEventNativeData['empty']; get eventInitData(): TvmEvmEventNativeData['eventInitData']; get initializer(): TvmEvmEventNativeData['initializer']; get meta(): TvmEvmEventNativeData['meta']; get rejects(): TvmEvmEventNativeData['rejects']; get requiredVotes(): TvmEvmEventNativeData['requiredVotes']; get signatures(): TvmEvmEventNativeData['signatures']; get status(): TvmEvmEventNativeData['status']; decodeEvent(args: DecodeEventParams<typeof TvmEvmEventNativeAbi>): Promise<TvmEvmEventNativeDecodedEvent | undefined>; decodeTransaction(args: DecodeTransactionParams<typeof TvmEvmEventNativeAbi>): Promise<TvmEvmEventNativeDecodedTransaction | undefined>; decodeTransactionEvents(transaction: Transaction): Promise<TvmEvmEventNativeDecodedEvent[]>; }