@broxus/js-bridge-essentials
Version:
Bridge JavaScript Essentials library
56 lines (55 loc) • 3.86 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 TonEvmEventAlienAbi } from '../../models/ton-evm-event-alien/abi';
import { type TonEvmEventAlienDecodedData, type TonEvmEventAlienDecodedEvent, type TonEvmEventAlienDecodedTransaction, type TonEvmEventAlienDetails, TonEvmEventAlienUtils } from '../../models/ton-evm-event-alien/TonEvmEventAlienUtils';
export interface TonEvmEventAlienCtorOptions {
watchDebounceDelay?: number;
}
export interface TonEvmEventAlienCreateOptions extends Syncable, TonEvmEventAlienCtorOptions, Watchable {
watchCallback?: VoidFunction;
}
export interface TonEvmEventAlienData extends TonEvmEventAlienDetails {
decodedData: TonEvmEventAlienDecodedData;
}
export declare class TonEvmEventAlien extends SmartContractModel<TonEvmEventAlienData> {
protected readonly _connection: ProviderRpcClient;
protected readonly options?: Readonly<TonEvmEventAlienCtorOptions> | undefined;
protected readonly _provider?: ProviderRpcClient | undefined;
static Utils: typeof TonEvmEventAlienUtils;
/**
* @param {ProviderRpcClient} _connection Standalone RPC client that doesn't require connection to the TVM wallet provider
* @param {Address | string} address Alien Event root address
* @param {Readonly<TonEvmEventAlienCtorOptions>} [options] (optional) Alien 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<TonEvmEventAlienCtorOptions> | undefined, _provider?: ProviderRpcClient | undefined);
/**
* @param {ProviderRpcClient} connection Standalone RPC client that doesn't require connection to the TVM wallet provider
* @param {Address | string} address Alien Event root address
* @param {Readonly<TonEvmEventAlienCreateOptions>} [options] (optional) Alien 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<TonEvmEventAlienCreateOptions>, provider?: ProviderRpcClient): Promise<TonEvmEventAlien>;
sync(options?: Forceable & Silentable): Promise<void>;
watch(callback?: SmartContractWatchCallback<TonEvmEventAlienData>): Promise<Subscriber>;
unwatch(): Promise<void>;
nonce(): Promise<string>;
recipient(): Promise<string>;
relayRound(): Promise<Address>;
roundNumber(): Promise<number>;
sender(): Promise<Address>;
get balance(): TonEvmEventAlienData['balance'];
get confirms(): TonEvmEventAlienData['confirms'];
get decodedData(): TonEvmEventAlienData['decodedData'];
get empty(): TonEvmEventAlienData['empty'];
get eventInitData(): TonEvmEventAlienData['eventInitData'];
get initializer(): TonEvmEventAlienData['initializer'];
get meta(): TonEvmEventAlienData['meta'];
get rejects(): TonEvmEventAlienData['rejects'];
get requiredVotes(): TonEvmEventAlienData['requiredVotes'];
get signatures(): TonEvmEventAlienData['signatures'];
get status(): TonEvmEventAlienData['status'];
decodeEvent(args: DecodeEventParams<typeof TonEvmEventAlienAbi>): Promise<TonEvmEventAlienDecodedEvent | undefined>;
decodeTransaction(args: DecodeTransactionParams<typeof TonEvmEventAlienAbi>): Promise<TonEvmEventAlienDecodedTransaction | undefined>;
decodeTransactionEvents(transaction: Transaction): Promise<TonEvmEventAlienDecodedEvent[]>;
}