yanchengPowerSupply/node_modules/mxdraw/dist/lib/MxModule/MxCADObject/index.d.ts

64 lines
1.3 KiB
TypeScript
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

/** @module MxCADObject */
export interface MxCADLayerTableRecord {
id: number;
name: string;
color: number;
off: boolean;
}
/**
* MxCAD 对象,用来实现在线编辑功能
*
*/
export default class MxCADObject {
private _mxCAD;
constructor(mxCAD: any);
/**
* 新建一个图纸
* @example
* ```typescript
*
* ```
*/
newFile(): void;
/** 撤销操作 */
undo(): void;
/**
* 打开个CAD文件
* @example
* ```typescript
*
* ```
*/
openFile(file: string, retfun?: (ret: Object) => void): void;
/**
* 保存CAD文件
* 文件保存路径在bin/release/ini.json, 中server.savepath设置。默认保存到bin/release/public/save目录下。
* @example
* ```typescript
*
* ```
*/
saveFile(file: string, retfun: (ret: Object) => void): void;
/**
* 从服务器上得到显示数据
* @example
* ```typescript
*
* ```
*/
getDisplayFromServer(): void;
/**
* 获取打开的文件名称
* @param file 文件路径
* @param retfun 保存文件后的回调函数
*
* */
getFileName(): string;
/**
* 获取全部图层数据
* @retruns 全部图层数据
*
* */
getAllLayerData(): MxCADLayerTableRecord[];
}