import { IpcRegistrar } from "./ipc-registrar";
import type { LensMainExtension } from "../lens-main-extension";
import type { Disposer } from "@openlens/utilities";
export declare abstract class IpcMain extends IpcRegistrar {
    private readonly dependencies;
    constructor(extension: LensMainExtension);
    /**
     * Listen for broadcasts within your extension
     * @param channel The channel to listen for broadcasts on
     * @param listener The function that will be called with the arguments of the broadcast
     * @returns An optional disposer, Lens will cleanup when the extension is disabled or uninstalled even if this is not called
     */
    listen(channel: string, listener: (event: Electron.IpcRendererEvent, ...args: any[]) => any): Disposer;
    /**
     * Declare a RPC over `channel`. Lens will cleanup when the extension is disabled or uninstalled
     * @param channel The name of the RPC
     * @param handler The remote procedure that is called
     */
    handle(channel: string, handler: (event: Electron.IpcMainInvokeEvent, ...args: any[]) => any): void;
}
