@broxus/js-bridge-essentials
Version:
Bridge JavaScript Essentials library
51 lines (50 loc) • 3.33 kB
TypeScript
import { type Forceable, type Silentable, type SmartContractWatchCallback, type Syncable, type Watchable, SmartContractModel } from '@broxus/js-core';
import { type Address, type DecodeEventParams, type DecodeTransactionParams, type ProviderRpcClient, type Subscriber, type Transaction } from 'everscale-inpage-provider';
import { type TvmTvmBaseEventAbi } from '../../models/tvm-tvm-base-event/abi';
import { type TvmTvmBaseEventDecodedEvent, type TvmTvmBaseEventDecodedTransaction, type TvmTvmBaseEventDetails, TvmTvmBaseEventUtils } from '../../models/tvm-tvm-base-event/TvmTvmBaseEventUtils';
export interface TvmTvmBaseEventCtorOptions {
watchDebounceDelay?: number;
}
export interface TvmTvmBaseEventCreateOptions extends Syncable, TvmTvmBaseEventCtorOptions, Watchable {
watchCallback?: VoidFunction;
}
export interface TvmTvmBaseEventData extends TvmTvmBaseEventDetails {
}
export declare class TvmTvmBaseEvent extends SmartContractModel<TvmTvmBaseEventData> {
protected readonly _connection: ProviderRpcClient;
protected readonly options?: Readonly<TvmTvmBaseEventCtorOptions> | undefined;
protected readonly _provider?: ProviderRpcClient | undefined;
static Utils: typeof TvmTvmBaseEventUtils;
/**
* @param {ProviderRpcClient} _connection Standalone RPC client that doesn't require connection
* to the TVM wallet provider
* @param {Address | string} address Base Event root address
* @param {Readonly<TvmTvmBaseEventCtorOptions>} [options] (optional) Base 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<TvmTvmBaseEventCtorOptions> | undefined, _provider?: ProviderRpcClient | undefined);
/**
* @param {ProviderRpcClient} connection Standalone RPC client that doesn't require connection
* to the TVM wallet provider
* @param {Address | string} address Base Event root address
* @param {Readonly<TvmTvmBaseEventCreateOptions>} [options] (optional) Base 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?: Readonly<TvmTvmBaseEventCreateOptions>, provider?: ProviderRpcClient): Promise<TvmTvmBaseEvent>;
sync(options?: Forceable & Silentable): Promise<void>;
watch(callback?: SmartContractWatchCallback<TvmTvmBaseEventData>): Promise<Subscriber>;
unwatch(): Promise<void>;
nonce(): Promise<string>;
eventInitialBalance(): Promise<string>;
get eventInitData(): TvmTvmBaseEventData['eventInitData'];
get initializer(): TvmTvmBaseEventData['initializer'];
get meta(): TvmTvmBaseEventData['meta'];
get status(): TvmTvmBaseEventData['status'];
decodeEvent(args: DecodeEventParams<typeof TvmTvmBaseEventAbi>): Promise<TvmTvmBaseEventDecodedEvent | undefined>;
decodeTransaction(args: DecodeTransactionParams<typeof TvmTvmBaseEventAbi>): Promise<TvmTvmBaseEventDecodedTransaction | undefined>;
decodeTransactionEvents(transaction: Transaction): Promise<TvmTvmBaseEventDecodedEvent[]>;
}