UNPKG

@alilc/lowcode-shell

Version:

Shell Layer for AliLowCodeEngine

21 lines (20 loc) 1.06 kB
import { IPublicApiCommand, IPublicModelPluginContext, IPublicTypeCommand, IPublicTypeCommandHandlerArgs, IPublicTypeListCommand } from '@alilc/lowcode-types'; import { commandSymbol, pluginContextSymbol } from '../symbols'; import { ICommand, ICommandOptions } from '@alilc/lowcode-editor-core'; declare const optionsSymbol: unique symbol; export declare class Command implements IPublicApiCommand { [commandSymbol]: ICommand; [optionsSymbol]?: ICommandOptions; [pluginContextSymbol]?: IPublicModelPluginContext; constructor(innerCommand: ICommand, pluginContext?: IPublicModelPluginContext, options?: ICommandOptions); registerCommand(command: IPublicTypeCommand): void; batchExecuteCommand(commands: { name: string; args: IPublicTypeCommandHandlerArgs; }[]): void; executeCommand(name: string, args: IPublicTypeCommandHandlerArgs): void; listCommands(): IPublicTypeListCommand[]; unregisterCommand(name: string): void; onCommandError(callback: (name: string, error: Error) => void): void; } export {};