import { EventCallback, IExternalEventBus, IOptionsList, ITabulator } from '../../../../../../types/src/table';

export default class ExternalEventBus implements IExternalEventBus {
    table: ITabulator;
    events: Record<string, EventCallback[]>;
    optionsList: IOptionsList | Record<string, any>;
    subscriptionNotifiers: Record<string, Array<(subscribed: boolean) => void>>;
    dispatch: (key: string, ...args: any[]) => any;
    debug: boolean | string[] | undefined;
    constructor(table: ITabulator, optionsList: IOptionsList | Record<string, any>, debug?: boolean | string[]);
    subscriptionChange(key: string, callback: (subscribed: boolean) => void): void;
    subscribe(key: string, callback: EventCallback): void;
    unsubscribe(key: string, callback?: EventCallback): void;
    subscribed(key: string): boolean;
    _notifySubscriptionChange(key: string, subscribed: boolean): void;
    _dispatch(key: string, ...args: any[]): any;
    _debugDispatch(key: string, ...args: any[]): any;
}
