@omnia/fx
Version:
Provide Omnia Fx typings and tooling for clientside Omnia development.
12 lines (11 loc) • 581 B
TypeScript
import { WorkerProxyFunction } from "../models";
export declare class WorkerProxy {
static _worker: Worker;
private static _initialized;
private static _handlers;
private static _promiseResolvers;
static call<TParamType, TReturnType>(topic: WorkerProxyFunction<TParamType, TReturnType>, parameter: TParamType): Promise<TReturnType>;
static addFunction<TSendType, TReturnType>(topic: WorkerProxyFunction<TSendType, TReturnType>, handler: (data: TSendType) => TReturnType): void;
private static ensureInitialized;
private static callHandlerMessage;
}