import { Contribution } from 'mana-syringe'; import type { Registry } from '@antv/x6'; import { Node as X6Node, Edge as X6Edge } from '@antv/x6'; import type { IGraphPipelineCommand } from '../command/interface'; import type { MaybePromise } from '../common/types'; import type { IRuntimeHook } from '@antv/xflow-hook/es/interface'; import { IGraphProvider } from '../xflow-main/graph/graph-provider'; import { IGraphCommandService } from '../command/interface'; import { IModelService } from '../model-service'; import { IFrontendApplicationContribution } from './interface'; export { IFrontendApplicationContribution } from './interface'; export declare class FrontendApplication { /** app的扩展 */ protected readonly contributions: Contribution.Provider; /** graphProvider */ readonly graphProvider: IGraphProvider; /** commandService */ readonly commandService: IGraphCommandService; /** modelService */ readonly modelService: IModelService; /** 启动app */ start(): Promise; /** 获取画布实例 */ getGraphInstance: () => Promise; /** 获取画布配置项 */ getGraphConfig: () => Promise; /** 获取画布配置项 */ getGraphData: () => Promise<{ nodes: import("..").NsGraph.INodeConfig[]; edges: import("..").NsGraph.IEdgeConfig[]; }>; /** 获取画布所有节点 */ getAllNodes: () => Promise[]>; /** 获取画布节点 */ getNodeById: (nodeId: string) => Promise>; /** 获取画布所有连线 */ getAllEdges: () => Promise[]>; /** 获取画布连线 */ getEdgeById: (edgeId: string) => Promise>; /** 更新节点样式 */ updateNodeAttrs: (node: string | X6Node, attrs: Registry.Attr.CellAttrs) => Promise; /** 更新连线样式 */ updateEdgeAttrs: (edge: string | X6Edge, attrs: Registry.Attr.CellAttrs) => Promise; /** 平移画布 */ translateGraph: (tx: number, ty: number) => Promise; /** 暴露命令的执行接口 */ executeCommand(commandId: string, cmdArgs: Args, hook?: IRuntimeHook): Promise; reactNodeRender: import("@antv/xflow-hook").HookHub>>, Map>>>; reactEdgeLabelRender: import("@antv/xflow-hook").HookHub>>, Map>>>; afterGraphInit: import("@antv/xflow-hook").HookHub; beforeGraphDestroy: import("@antv/xflow-hook").HookHub; x6Events: import("@antv/xflow-hook").HookHub; }>>; /** 暴露命令的批量执行接口 */ executeCommandPipeline(cmdOptions: IGraphPipelineCommand[]): Promise; reactNodeRender: import("@antv/xflow-hook").HookHub>>, Map>>>; reactEdgeLabelRender: import("@antv/xflow-hook").HookHub>>, Map>>>; afterGraphInit: import("@antv/xflow-hook").HookHub; beforeGraphDestroy: import("@antv/xflow-hook").HookHub; x6Events: import("@antv/xflow-hook").HookHub; }>>; /** * Register global event listeners. */ protected registerEventListeners(): void; /** * Initialize and start the frontend application contributions. */ protected startContributions(): Promise; /** * Stop the frontend application contributions. This is called when the window is unloaded. */ protected stopContributions(): void; protected measure(name: string, fn: () => MaybePromise): Promise; }