import { BasicEvent, Event, IDisposable, IExtensionProps } from '@opensumi/ide-core-common';
import { IExtension, IExtensionMetaData } from '../common';
import { Extension } from './extension';
export type Serializable = any;
export interface IExtHostEventPayload {
    eventName: string;
    eventArgs: Serializable[];
}
export declare class ExtHostEvent extends BasicEvent<IExtHostEventPayload> {
}
export declare abstract class IActivationEventService {
    abstract fireEvent(topic: string, data?: string): Promise<void>;
    abstract onEvent(event: string, listener: any): IDisposable;
    abstract addWildCardTopic(topic: string): IDisposable;
    activatedEventSet: Set<string>;
}
/**
 * 插件实例的数据管理
 */
export declare abstract class AbstractExtInstanceManagementService {
    abstract dispose(): void;
    abstract onDidChange: Event<void>;
    /**
     * 通过路径销毁插件实例 dispose
     */
    abstract disposeExtensionInstancesByPath(paths: Array<string>): void;
    /**
     * 获取所有插件实例
     */
    abstract getExtensionInstances(): Extension[];
    /**
     * 重置所有插件实例 (reset)
     */
    abstract resetExtensionInstances(): void;
    /**
     * 销毁所有插件实例 (dispose)
     */
    abstract disposeExtensionInstances(): void;
    /**
     * 通过 extension path 获取插件实例
     */
    abstract getExtensionInstanceByPath(extensionPath: string): Extension | undefined;
    /**
     * 通过 extension id 获取插件实例
     */
    abstract getExtensionInstanceByExtId(extensionId: string): Extension | undefined;
    /**
     * 删除插件实例
     */
    abstract deleteExtensionInstanceByPath(extensionPath: string): void;
    /**
     * 添加插件实例
     */
    abstract addExtensionInstance(extension: Extension): void;
    /**
     * 检查插件是否激活
     */
    abstract checkExtensionEnable(extension: IExtensionMetaData): Promise<boolean>;
    /**
     * 通过 extensionPath 创建一个 (内置) 插件实例
     */
    abstract createExtensionInstance(extensionPathOrMetaData: IExtensionMetaData | string, isBuiltin: boolean, isDevelopment?: boolean): Promise<Extension | undefined>;
    /**
     * 判断插件是否为内置插件
     */
    abstract checkIsBuiltin(extensionMetaData: IExtensionMetaData): boolean;
    /**
     * 判断插件是否为开发模式
     */
    abstract checkIsDevelopment(extensionMetaData: IExtensionMetaData): boolean;
}
export declare class ExtensionApiReadyEvent extends BasicEvent<void> {
}
/**
 * 扩展被激活前的事件
 */
export declare class ExtensionBeforeActivateEvent extends BasicEvent<void> {
}
export declare class ExtensionWillActivateEvent extends BasicEvent<IExtension> {
}
export declare class ExtensionWillContributeEvent extends BasicEvent<IExtensionMetaData> {
}
export declare class ExtensionDidActivatedEvent extends BasicEvent<IExtensionProps> {
}
/**
 * 插件扫描完成后的事件
 */
export declare class ExtensionsInitializedEvent extends BasicEvent<IExtension[]> {
}
/**
 * 插件卸载时的事件
 */
export declare class ExtensionDidUninstalledEvent extends BasicEvent<void> {
}
/**
 * 插件启用时的事件
 */
export declare class ExtensionDidEnabledEvent extends BasicEvent<IExtensionProps> {
}
//# sourceMappingURL=types.d.ts.map