@jlceda/pro-api-types 0.1.130 → 0.1.132
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.d.ts +170 -24
- package/package.json +1 -1
package/index.d.ts
CHANGED
|
@@ -86,7 +86,7 @@ declare class DMT_EditorControl {
|
|
|
86
86
|
*
|
|
87
87
|
* @beta
|
|
88
88
|
* @param libraryUuid - 库 UUID,可以使用 {@link LIB_LibrariesList} 内的接口获取
|
|
89
|
-
* @param libraryType -
|
|
89
|
+
* @param libraryType - ��类型,支持符号和封装
|
|
90
90
|
* @param uuid - 符号、封装 UUID
|
|
91
91
|
* @param splitScreenId - 分屏 ID,即 {@link DMT_EditorControl.getSplitScreenTree} 方法获取到的 {@link IDMT_EditorSplitScreenItem.id}
|
|
92
92
|
* @returns 标签页 ID,如若为 `undefined`,则打开文档失败
|
|
@@ -248,8 +248,31 @@ declare class DMT_EditorControl {
|
|
|
248
248
|
top: number;
|
|
249
249
|
bottom: number;
|
|
250
250
|
} | false>;
|
|
251
|
-
|
|
252
|
-
|
|
251
|
+
/**
|
|
252
|
+
* 生成指示标记
|
|
253
|
+
*
|
|
254
|
+
* @beta
|
|
255
|
+
* @remarks 指示标记外形数据中,原理图、符号画布坐标单位跨度为 0.01inch,PCB、封装画布坐标单位跨度为 mil
|
|
256
|
+
* @param markers - 指示标记外形对象数组
|
|
257
|
+
* @param color - 指示标记颜色
|
|
258
|
+
* @param tabId - 标签页 ID,如若未传入,则为最后输入焦点的画布
|
|
259
|
+
* @returns 指示标记生成是否成功,`false` 表示画布不支持该操作或 `tabId` 不存在
|
|
260
|
+
*/
|
|
261
|
+
generateIndicatorMarkers(markers: Array<IDMT_IndicatorMarkerShape>, color?: {
|
|
262
|
+
r: number;
|
|
263
|
+
g: number;
|
|
264
|
+
b: number;
|
|
265
|
+
alpha: number;
|
|
266
|
+
}, tabId?: string): Promise<boolean>;
|
|
267
|
+
/**
|
|
268
|
+
* 移除指示标记
|
|
269
|
+
*
|
|
270
|
+
* @beta
|
|
271
|
+
* @remarks 本接口会移除所有已生成的指示标记
|
|
272
|
+
* @param tabId - 标签页 ID,如若未传入,则为最后输入焦点的画布
|
|
273
|
+
* @returns 指示标记移除是否成功,`false` 表示画布不支持该操作或 `tabId` 不存在
|
|
274
|
+
*/
|
|
275
|
+
removeIndicatorMarkers(tabId?: string): Promise<boolean>;
|
|
253
276
|
}
|
|
254
277
|
|
|
255
278
|
/**
|
|
@@ -456,7 +479,7 @@ declare class DMT_Pcb {
|
|
|
456
479
|
* 删除 PCB
|
|
457
480
|
*
|
|
458
481
|
* @public
|
|
459
|
-
* @remarks 如若 PCB 已关联复用模块(在工程库内存在同名的复用模块符号),则删除 PCB
|
|
482
|
+
* @remarks 如若 PCB 已关联复用模块(在工程库内存在同名的复用模块符号),则删除 PCB 时将同步删除关联的原��图和复用模块符号,复用模块符号不可删除则跳过
|
|
460
483
|
* @param pcbUuid - PCB UUID
|
|
461
484
|
* @returns 操作是否成功
|
|
462
485
|
*/
|
|
@@ -823,6 +846,7 @@ declare class EDA {
|
|
|
823
846
|
pcb_PrimitivePad: PCB_PrimitivePad;
|
|
824
847
|
pcb_PrimitivePolyline: PCB_PrimitivePolyline;
|
|
825
848
|
pcb_PrimitivePour: PCB_PrimitivePour;
|
|
849
|
+
pcb_PrimitivePoured: PCB_PrimitivePoured;
|
|
826
850
|
pcb_PrimitiveRegion: PCB_PrimitiveRegion;
|
|
827
851
|
pcb_PrimitiveVia: PCB_PrimitiveVia;
|
|
828
852
|
pcb_SelectControl: PCB_SelectControl;
|
|
@@ -1426,6 +1450,18 @@ declare enum EPCB_PrimitivePadShapeType {
|
|
|
1426
1450
|
POLYLINE_COMPLEX_POLYGON = "POLYGON"
|
|
1427
1451
|
}
|
|
1428
1452
|
|
|
1453
|
+
/**
|
|
1454
|
+
* 焊盘类型
|
|
1455
|
+
*
|
|
1456
|
+
* @public
|
|
1457
|
+
*/
|
|
1458
|
+
declare enum EPCB_PrimitivePadType {
|
|
1459
|
+
/** 焊盘 */
|
|
1460
|
+
NORMAL = "NORMAL",
|
|
1461
|
+
/** 测试点 */
|
|
1462
|
+
TEST = "TEST"
|
|
1463
|
+
}
|
|
1464
|
+
|
|
1429
1465
|
/**
|
|
1430
1466
|
* 覆铜填充方法
|
|
1431
1467
|
*
|
|
@@ -1494,7 +1530,9 @@ declare enum EPCB_PrimitiveType {
|
|
|
1494
1530
|
/** 图像 */
|
|
1495
1531
|
IMAGE = "Image",
|
|
1496
1532
|
/** 二进制内嵌对象 */
|
|
1497
|
-
OBJECT = "Object"
|
|
1533
|
+
OBJECT = "Object",
|
|
1534
|
+
/** 覆铜填充 */
|
|
1535
|
+
POURED = "Poured"
|
|
1498
1536
|
}
|
|
1499
1537
|
|
|
1500
1538
|
/**
|
|
@@ -2038,14 +2076,6 @@ declare interface IDMT_IndicatorMarkerShape {
|
|
|
2038
2076
|
* 线段 | 圆弧:起始点 Y
|
|
2039
2077
|
*/
|
|
2040
2078
|
startY?: number;
|
|
2041
|
-
/**
|
|
2042
|
-
* 圆弧:参考点 X
|
|
2043
|
-
*/
|
|
2044
|
-
referenceX?: number;
|
|
2045
|
-
/**
|
|
2046
|
-
* 圆弧:参考点 Y
|
|
2047
|
-
*/
|
|
2048
|
-
referenceY?: number;
|
|
2049
2079
|
/**
|
|
2050
2080
|
* 线段 | 圆弧:终止点 X
|
|
2051
2081
|
*/
|
|
@@ -2070,6 +2100,10 @@ declare interface IDMT_IndicatorMarkerShape {
|
|
|
2070
2100
|
* 矩形:右 X
|
|
2071
2101
|
*/
|
|
2072
2102
|
right?: number;
|
|
2103
|
+
/**
|
|
2104
|
+
* 圆弧:角度
|
|
2105
|
+
*/
|
|
2106
|
+
angle?: number;
|
|
2073
2107
|
}
|
|
2074
2108
|
|
|
2075
2109
|
/**
|
|
@@ -2996,7 +3030,7 @@ declare class IPCB_PrimitiveArc implements IPCB_Primitive {
|
|
|
2996
3030
|
*/
|
|
2997
3031
|
getState_PrimitiveLock(): boolean;
|
|
2998
3032
|
/**
|
|
2999
|
-
*
|
|
3033
|
+
* 设置属性��态:网络名称
|
|
3000
3034
|
*
|
|
3001
3035
|
* @beta
|
|
3002
3036
|
* @param net - 网络名称
|
|
@@ -4627,6 +4661,8 @@ declare class IPCB_PrimitivePad implements IPCB_Primitive {
|
|
|
4627
4661
|
protected heatWelding: IPCB_PrimitivePadHeatWelding | null;
|
|
4628
4662
|
/** 是否锁定 */
|
|
4629
4663
|
protected primitiveLock: boolean;
|
|
4664
|
+
/** 焊盘类型 */
|
|
4665
|
+
protected padType: EPCB_PrimitivePadType;
|
|
4630
4666
|
/* Excluded from this release type: __constructor */
|
|
4631
4667
|
/**
|
|
4632
4668
|
* 在 PCB 画布中创建图元
|
|
@@ -4643,7 +4679,7 @@ declare class IPCB_PrimitivePad implements IPCB_Primitive {
|
|
|
4643
4679
|
*/
|
|
4644
4680
|
getState_PrimitiveType(): EPCB_PrimitiveType;
|
|
4645
4681
|
/**
|
|
4646
|
-
*
|
|
4682
|
+
* 获取属性状态:图元 ID
|
|
4647
4683
|
*
|
|
4648
4684
|
* @public
|
|
4649
4685
|
* @returns 图元 ID
|
|
@@ -4768,6 +4804,13 @@ declare class IPCB_PrimitivePad implements IPCB_Primitive {
|
|
|
4768
4804
|
* @returns 是否锁定
|
|
4769
4805
|
*/
|
|
4770
4806
|
getState_PrimitiveLock(): boolean;
|
|
4807
|
+
/**
|
|
4808
|
+
* 获取属性状态:焊盘类型
|
|
4809
|
+
*
|
|
4810
|
+
* @public
|
|
4811
|
+
* @returns 焊盘类型
|
|
4812
|
+
*/
|
|
4813
|
+
getState_PadType(): EPCB_PrimitivePadType;
|
|
4771
4814
|
/**
|
|
4772
4815
|
* 设置属性状态:层
|
|
4773
4816
|
*
|
|
@@ -4970,6 +5013,14 @@ declare class IPCB_PrimitivePad implements IPCB_Primitive {
|
|
|
4970
5013
|
* @returns 尺寸标注图元对象
|
|
4971
5014
|
*/
|
|
4972
5015
|
done(): Promise<IPCB_PrimitivePad>;
|
|
5016
|
+
/**
|
|
5017
|
+
* 设置属性状态:焊盘类型
|
|
5018
|
+
*
|
|
5019
|
+
* @beta
|
|
5020
|
+
* @param padType - 焊盘类型
|
|
5021
|
+
* @returns 焊盘图元对象
|
|
5022
|
+
*/
|
|
5023
|
+
private setState_PadType;
|
|
4973
5024
|
}
|
|
4974
5025
|
|
|
4975
5026
|
/**
|
|
@@ -5377,6 +5428,8 @@ declare class IPCB_PrimitivePour implements IPCB_Primitive {
|
|
|
5377
5428
|
* @returns 覆铜边框图元对象
|
|
5378
5429
|
*/
|
|
5379
5430
|
done(): Promise<IPCB_PrimitivePour>;
|
|
5431
|
+
/* Excluded from this release type: getCopperRegion */
|
|
5432
|
+
/* Excluded from this release type: rebuildCopperRegion */
|
|
5380
5433
|
/**
|
|
5381
5434
|
* 转换到:填充图元(默认是填充区域)
|
|
5382
5435
|
*
|
|
@@ -5400,6 +5453,77 @@ declare class IPCB_PrimitivePour implements IPCB_Primitive {
|
|
|
5400
5453
|
convertToRegion(): Promise<IPCB_PrimitiveRegion>;
|
|
5401
5454
|
}
|
|
5402
5455
|
|
|
5456
|
+
/**
|
|
5457
|
+
* 覆铜填充图元
|
|
5458
|
+
*
|
|
5459
|
+
* @public
|
|
5460
|
+
*/
|
|
5461
|
+
declare class IPCB_PrimitivePoured implements IPCB_Primitive {
|
|
5462
|
+
/** 异步 */
|
|
5463
|
+
private async;
|
|
5464
|
+
/** 图元类型 */
|
|
5465
|
+
private readonly primitiveType;
|
|
5466
|
+
/** 覆铜边框图元 ID */
|
|
5467
|
+
private pourPrimitiveId;
|
|
5468
|
+
/** 覆铜填充区域 */
|
|
5469
|
+
private pourFills;
|
|
5470
|
+
/** 图元 ID */
|
|
5471
|
+
private primitiveId;
|
|
5472
|
+
/* Excluded from this release type: __constructor */
|
|
5473
|
+
/* Excluded from this release type: create */
|
|
5474
|
+
/**
|
|
5475
|
+
* 获取属性状态:图元类型
|
|
5476
|
+
*
|
|
5477
|
+
* @public
|
|
5478
|
+
* @returns 图元类型
|
|
5479
|
+
*/
|
|
5480
|
+
getState_PrimitiveType(): EPCB_PrimitiveType;
|
|
5481
|
+
/**
|
|
5482
|
+
* 获取属性状态:图元 ID
|
|
5483
|
+
*
|
|
5484
|
+
* @public
|
|
5485
|
+
* @returns 图元 ID
|
|
5486
|
+
*/
|
|
5487
|
+
getState_PrimitiveId(): string;
|
|
5488
|
+
/**
|
|
5489
|
+
* 获取属性状态:覆铜边框图元 ID
|
|
5490
|
+
*
|
|
5491
|
+
* @public
|
|
5492
|
+
* @returns 覆铜边框图元 ID
|
|
5493
|
+
*/
|
|
5494
|
+
getState_PourPrimitiveId(): string;
|
|
5495
|
+
/**
|
|
5496
|
+
* 获取属性状态:覆铜填充区域
|
|
5497
|
+
*
|
|
5498
|
+
* @public
|
|
5499
|
+
* @returns 覆铜填充区域
|
|
5500
|
+
*/
|
|
5501
|
+
getState_PourFills(): Array<IPCB_PrimitivePouredPourFill>;
|
|
5502
|
+
/* Excluded from this release type: toAsync */
|
|
5503
|
+
/* Excluded from this release type: toSync */
|
|
5504
|
+
/* Excluded from this release type: isAsync */
|
|
5505
|
+
/* Excluded from this release type: reset */
|
|
5506
|
+
/* Excluded from this release type: done */
|
|
5507
|
+
/* Excluded from this release type: convertToFill */
|
|
5508
|
+
/* Excluded from this release type: addSolderMaskFill */
|
|
5509
|
+
}
|
|
5510
|
+
|
|
5511
|
+
/**
|
|
5512
|
+
* 覆铜填充区域
|
|
5513
|
+
*
|
|
5514
|
+
* @public
|
|
5515
|
+
*/
|
|
5516
|
+
declare interface IPCB_PrimitivePouredPourFill {
|
|
5517
|
+
/** 复杂多边形 */
|
|
5518
|
+
path: IPCB_ComplexPolygon;
|
|
5519
|
+
/** 线宽 */
|
|
5520
|
+
lineWidth: number;
|
|
5521
|
+
/** 是否填充 */
|
|
5522
|
+
fill: boolean;
|
|
5523
|
+
/** ID */
|
|
5524
|
+
id: string;
|
|
5525
|
+
}
|
|
5526
|
+
|
|
5403
5527
|
/**
|
|
5404
5528
|
* 区域图元
|
|
5405
5529
|
*
|
|
@@ -8141,7 +8265,7 @@ declare class ISCH_PrimitiveText implements ISCH_Primitive {
|
|
|
8141
8265
|
}
|
|
8142
8266
|
|
|
8143
8267
|
/**
|
|
8144
|
-
*
|
|
8268
|
+
* 导��图元
|
|
8145
8269
|
*
|
|
8146
8270
|
* @public
|
|
8147
8271
|
*/
|
|
@@ -10169,7 +10293,7 @@ declare class PCB_ManufactureData {
|
|
|
10169
10293
|
* 如若启用,则会存在弹窗等待用户进行交互,且无法使用 `ignoreWarning` 参数忽略警告,
|
|
10170
10294
|
* 即 `ignoreWarning` 参数将被忽略;
|
|
10171
10295
|
*
|
|
10172
|
-
*
|
|
10296
|
+
* 如若���用,则在调用后不会有任何 EDA 内部弹窗,程序执行静默检查,
|
|
10173
10297
|
* 如若达成下单条件,将返回 `true` 并在新标签页打开下单页面
|
|
10174
10298
|
* @param ignoreWarning - 在非交互式检查时忽略警告
|
|
10175
10299
|
*
|
|
@@ -10556,7 +10680,7 @@ declare class PCB_PrimitiveComponent implements IPCB_PrimitiveAPI {
|
|
|
10556
10680
|
*
|
|
10557
10681
|
* @beta
|
|
10558
10682
|
* @remarks 如若传入多个图元 ID,任意图元 ID 未匹配到不影响其它图元的返回,即可能返回少于传入的图元 ID 数量的图元对象
|
|
10559
|
-
* @param primitiveIds - 器件的图元 ID
|
|
10683
|
+
* @param primitiveIds - 器件的图元 ID,可以为字符串或字符串数组,如若为数组,则返回的也是数组
|
|
10560
10684
|
* @returns 器件图元对象,空数组表示获取失败
|
|
10561
10685
|
*/
|
|
10562
10686
|
get(primitiveIds: Array<string>): Promise<Array<IPCB_PrimitiveComponent>>;
|
|
@@ -10965,7 +11089,7 @@ declare class PCB_PrimitiveObject implements IPCB_PrimitiveAPI {
|
|
|
10965
11089
|
* @beta
|
|
10966
11090
|
* @param primitiveId - 图元 ID
|
|
10967
11091
|
* @param property - 修改参数
|
|
10968
|
-
* @returns
|
|
11092
|
+
* @returns 二进制内嵌对象图元对象,`undefined` 表示修改失败
|
|
10969
11093
|
*/
|
|
10970
11094
|
modify(primitiveId: string | IPCB_PrimitiveObject, property: {
|
|
10971
11095
|
layer?: TPCB_LayersOfObject;
|
|
@@ -11043,9 +11167,10 @@ declare class PCB_PrimitivePad implements IPCB_PrimitiveAPI {
|
|
|
11043
11167
|
* @param solderMaskAndPasteMaskExpansion - 阻焊/助焊扩展,`null` 表示遵循规则
|
|
11044
11168
|
* @param heatWelding - 热焊优化参数
|
|
11045
11169
|
* @param primitiveLock - 是否锁定
|
|
11170
|
+
* @param padType - 焊盘类型
|
|
11046
11171
|
* @returns 焊盘图元对象
|
|
11047
11172
|
*/
|
|
11048
|
-
create(layer: TPCB_LayersOfPad, padNumber: string, x: number, y: number, rotation?: number, pad?: TPCB_PrimitivePadShape, net?: string, hole?: TPCB_PrimitivePadHole | null, holeOffsetX?: number, holeOffsetY?: number, holeRotation?: number, metallization?: boolean, padFunction?: EPCB_PrimitivePadFunction, specialPad?: TPCB_PrimitiveSpecialPadShape, solderMaskAndPasteMaskExpansion?: IPCB_PrimitiveSolderMaskAndPasteMaskExpansion | null, heatWelding?: IPCB_PrimitivePadHeatWelding | null, primitiveLock?: boolean): Promise<IPCB_PrimitivePad | undefined>;
|
|
11173
|
+
create(layer: TPCB_LayersOfPad, padNumber: string, x: number, y: number, rotation?: number, pad?: TPCB_PrimitivePadShape, net?: string, hole?: TPCB_PrimitivePadHole | null, holeOffsetX?: number, holeOffsetY?: number, holeRotation?: number, metallization?: boolean, padFunction?: EPCB_PrimitivePadFunction, specialPad?: TPCB_PrimitiveSpecialPadShape, solderMaskAndPasteMaskExpansion?: IPCB_PrimitiveSolderMaskAndPasteMaskExpansion | null, heatWelding?: IPCB_PrimitivePadHeatWelding | null, primitiveLock?: boolean, padType?: EPCB_PrimitivePadType): Promise<IPCB_PrimitivePad | undefined>;
|
|
11049
11174
|
/**
|
|
11050
11175
|
* 删除焊盘
|
|
11051
11176
|
*
|
|
@@ -11107,7 +11232,7 @@ declare class PCB_PrimitivePad implements IPCB_PrimitiveAPI {
|
|
|
11107
11232
|
* @param primitiveLock - 是否锁定
|
|
11108
11233
|
* @returns 焊盘的图元 ID 数组
|
|
11109
11234
|
*/
|
|
11110
|
-
getAllPrimitiveId(layer?: TPCB_LayersOfPad, net?: string, primitiveLock?: boolean): Promise<Array<string>>;
|
|
11235
|
+
getAllPrimitiveId(layer?: TPCB_LayersOfPad, net?: string, primitiveLock?: boolean, padType?: EPCB_PrimitivePadType): Promise<Array<string>>;
|
|
11111
11236
|
/**
|
|
11112
11237
|
* 获取所有焊盘
|
|
11113
11238
|
*
|
|
@@ -11117,7 +11242,7 @@ declare class PCB_PrimitivePad implements IPCB_PrimitiveAPI {
|
|
|
11117
11242
|
* @param primitiveLock - 是否锁定
|
|
11118
11243
|
* @returns 焊盘图元对象数组
|
|
11119
11244
|
*/
|
|
11120
|
-
getAll(layer?: TPCB_LayersOfPad, net?: string, primitiveLock?: boolean): Promise<Array<IPCB_PrimitivePad>>;
|
|
11245
|
+
getAll(layer?: TPCB_LayersOfPad, net?: string, primitiveLock?: boolean, padType?: EPCB_PrimitivePadType): Promise<Array<IPCB_PrimitivePad>>;
|
|
11121
11246
|
}
|
|
11122
11247
|
|
|
11123
11248
|
/**
|
|
@@ -11288,6 +11413,21 @@ declare class PCB_PrimitivePour implements IPCB_PrimitiveAPI {
|
|
|
11288
11413
|
getAll(net?: string, layer?: TPCB_LayersOfCopper, primitiveLock?: boolean): Promise<Array<IPCB_PrimitivePour>>;
|
|
11289
11414
|
}
|
|
11290
11415
|
|
|
11416
|
+
/**
|
|
11417
|
+
* PCB & 封装 / 覆铜填充图元类
|
|
11418
|
+
*
|
|
11419
|
+
* @public
|
|
11420
|
+
*/
|
|
11421
|
+
declare class PCB_PrimitivePoured implements IPCB_PrimitiveAPI {
|
|
11422
|
+
/* Excluded from this release type: create */
|
|
11423
|
+
/* Excluded from this release type: delete */
|
|
11424
|
+
/* Excluded from this release type: modify */
|
|
11425
|
+
/* Excluded from this release type: get */
|
|
11426
|
+
/* Excluded from this release type: get */
|
|
11427
|
+
/* Excluded from this release type: getAllPrimitiveId */
|
|
11428
|
+
/* Excluded from this release type: getAll */
|
|
11429
|
+
}
|
|
11430
|
+
|
|
11291
11431
|
/**
|
|
11292
11432
|
* PCB & 封装 / 禁止区域和约束区域图元类
|
|
11293
11433
|
*
|
|
@@ -12243,7 +12383,13 @@ declare class SCH_PrimitiveComponent implements ISCH_PrimitiveAPI {
|
|
|
12243
12383
|
libraryUuid: string;
|
|
12244
12384
|
uuid: string;
|
|
12245
12385
|
} | ILIB_DeviceItem, subPartName?: string): Promise<boolean>;
|
|
12246
|
-
|
|
12386
|
+
/**
|
|
12387
|
+
* 获取所有器件的所有属性名称集合
|
|
12388
|
+
*
|
|
12389
|
+
* @beta
|
|
12390
|
+
* @returns 所有器件的所有属性名称集合
|
|
12391
|
+
*/
|
|
12392
|
+
getAllPropertyNames(): Promise<string[]>;
|
|
12247
12393
|
/* Excluded from this release type: getComponentDetail */
|
|
12248
12394
|
/* Excluded from this release type: checkComponentType */
|
|
12249
12395
|
}
|
|
@@ -12847,7 +12993,7 @@ declare class SCH_PrimitiveWire implements ISCH_PrimitiveAPI {
|
|
|
12847
12993
|
*
|
|
12848
12994
|
* @beta
|
|
12849
12995
|
* @param line - 多段线坐标组,每段都是连续的一组 `[x1, y1, x2, y2, x3, y3]` 所描述的线,如若多段线彼此无任何连接则创建将会失败
|
|
12850
|
-
* @param net -
|
|
12996
|
+
* @param net - 网络名称,如若未指定,则遵循:
|
|
12851
12997
|
* 1. 没有坐标落在任何图元上,则默认为空网络;
|
|
12852
12998
|
* 2. 有一个坐标点在某个网络的图元上,则跟随该图元的网络;
|
|
12853
12999
|
* 3. 有多个坐标点在多个不同网络的图元上,则创建失败
|