export interface ActionContext { sessionId: string; componentId?: string; dataSet?: string; value?: any; event?: any; } export interface ActionHandler { (context: ActionContext, ...args: any[]): Promise | any; } /** * 注册动作处理器 */ export declare const registerActionHandler: (name: string, handler: ActionHandler) => void; /** * 执行动作 */ export declare const executeAction: (actionString: string, context: ActionContext) => Promise; /** * ActionExecutor 对象 */ export declare const ActionExecutor: { execute: (actionString: string, context: ActionContext) => Promise; register: (name: string, handler: ActionHandler) => void; hasHandler: (name: string) => boolean; }; export default ActionExecutor;