@windypro-rourou/dsh-eda 0.1.4 → 0.1.5
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/README.md +1 -1
- package/lib/capabilities.js +3 -2
- package/lib/client.js +33 -0
- package/lib/index.js +89 -2
- package/package.json +10 -1
- package/skill/INDEX.md +10 -8
- package/skill/README.md +125 -0
- package/skill/README.zh-Hans.md +125 -0
- package/skill/SKILL.md +746 -746
- package/skill/format/index.md +152 -152
- package/skill/format/pcb/3d.md +166 -166
- package/skill/format/pcb/attr.md +63 -63
- package/skill/format/pcb/common.md +306 -306
- package/skill/format/pcb/component.md +132 -132
- package/skill/format/pcb/dimension.md +58 -58
- package/skill/format/pcb/index.md +17 -17
- package/skill/format/pcb/obj.md +43 -43
- package/skill/format/pcb/pad_via.md +151 -151
- package/skill/format/pcb/panel.md +64 -64
- package/skill/format/pcb/partition.md +43 -43
- package/skill/format/pcb/primitive.md +196 -196
- package/skill/format/pcb/rule.md +71 -71
- package/skill/format/pcb/shape.md +441 -441
- package/skill/format/pcb/text.md +62 -62
- package/skill/format/project/blob.md +30 -30
- package/skill/format/project/common.md +42 -42
- package/skill/format/project/group.md +62 -62
- package/skill/format/project/index.md +12 -12
- package/skill/format/project/instance.md +32 -32
- package/skill/format/project/meta.md +189 -189
- package/skill/format/project/variant.md +30 -30
- package/skill/format/schematic/attr.md +41 -41
- package/skill/format/schematic/common.md +47 -47
- package/skill/format/schematic/component.md +91 -91
- package/skill/format/schematic/index.md +14 -14
- package/skill/format/schematic/obj.md +41 -41
- package/skill/format/schematic/pin.md +59 -59
- package/skill/format/schematic/shape.md +231 -231
- package/skill/format/schematic/structure.md +53 -53
- package/skill/format/schematic/table.md +109 -109
- package/skill/format/schematic/text.md +47 -47
- package/skill/format/schematic/wire.md +132 -132
- package/skill/guide/ancillary-projects/easyeda-api-sdk.md +1 -0
- package/skill/guide/ancillary-projects/pro-api-types.md +5 -5
- package/skill/guide/ancillary-projects.md +10 -10
- package/skill/guide/cli.md +1510 -0
- package/skill/guide/error-handling.md +38 -38
- package/skill/guide/extension-json.md +135 -135
- package/skill/guide/extensions-marketplace.md +61 -61
- package/skill/guide/how-to-start.md +316 -301
- package/skill/guide/i18n.md +57 -57
- package/skill/guide/index.md +7 -7
- package/skill/guide/inline-frame.md +20 -20
- package/skill/guide/invoke-apis.md +81 -81
- package/skill/guide/stability.md +37 -37
- package/skill/references/_index.md +471 -398
- package/skill/references/_quick-reference.md +3103 -3028
- package/skill/references/classes/DMT_Board.md +537 -533
- package/skill/references/classes/DMT_EditorControl.md +1736 -1736
- package/skill/references/classes/DMT_Event.md +356 -356
- package/skill/references/classes/DMT_Folder.md +775 -775
- package/skill/references/classes/DMT_Panel.md +531 -531
- package/skill/references/classes/DMT_Pcb.md +579 -575
- package/skill/references/classes/DMT_Project.md +734 -573
- package/skill/references/classes/DMT_Schematic.md +1482 -1477
- package/skill/references/classes/DMT_SelectControl.md +96 -96
- package/skill/references/classes/DMT_Team.md +172 -172
- package/skill/references/classes/DMT_Workspace.md +198 -198
- package/skill/references/classes/EDA.md +1001 -961
- package/skill/references/classes/IPCB_ComplexPolygon.md +299 -299
- package/skill/references/classes/IPCB_Polygon.md +175 -175
- package/skill/references/classes/IPCB_PrimitiveArc.md +1901 -1901
- package/skill/references/classes/IPCB_PrimitiveAttribute.md +2993 -2993
- package/skill/references/classes/IPCB_PrimitiveComponent.md +2624 -2627
- package/skill/references/classes/IPCB_PrimitiveComponentPad.md +410 -410
- package/skill/references/classes/IPCB_PrimitiveDimension.md +1419 -1419
- package/skill/references/classes/IPCB_PrimitiveFill.md +1325 -1325
- package/skill/references/classes/IPCB_PrimitiveImage.md +1461 -1461
- package/skill/references/classes/IPCB_PrimitiveLine.md +1639 -1639
- package/skill/references/classes/IPCB_PrimitiveObject.md +1700 -1700
- package/skill/references/classes/IPCB_PrimitivePad.md +3155 -3155
- package/skill/references/classes/IPCB_PrimitivePolyline.md +1193 -1193
- package/skill/references/classes/IPCB_PrimitivePour.md +1858 -1858
- package/skill/references/classes/IPCB_PrimitivePoured.md +556 -556
- package/skill/references/classes/IPCB_PrimitiveRegion.md +1332 -1332
- package/skill/references/classes/IPCB_PrimitiveString.md +2315 -2315
- package/skill/references/classes/IPCB_PrimitiveVia.md +1588 -1588
- package/skill/references/classes/ISCH_PrimitiveArc.md +1676 -1676
- package/skill/references/classes/ISCH_PrimitiveAttribute.md +2541 -2541
- package/skill/references/classes/ISCH_PrimitiveBus.md +973 -973
- package/skill/references/classes/ISCH_PrimitiveCbbSymbolComponent.md +260 -260
- package/skill/references/classes/ISCH_PrimitiveCircle.md +1392 -1392
- package/skill/references/classes/ISCH_PrimitiveComponent.md +2910 -2913
- package/skill/references/classes/ISCH_PrimitiveComponentPin.md +155 -155
- package/skill/references/classes/ISCH_PrimitiveObject.md +960 -960
- package/skill/references/classes/ISCH_PrimitivePin.md +2402 -2402
- package/skill/references/classes/ISCH_PrimitivePolygon.md +1028 -1028
- package/skill/references/classes/ISCH_PrimitiveRectangle.md +1777 -1777
- package/skill/references/classes/ISCH_PrimitiveText.md +1771 -1771
- package/skill/references/classes/ISCH_PrimitiveWire.md +973 -973
- package/skill/references/classes/LIB_3DModel.md +782 -780
- package/skill/references/classes/LIB_Cbb.md +957 -957
- package/skill/references/classes/LIB_Classification.md +969 -965
- package/skill/references/classes/LIB_Device.md +1222 -1221
- package/skill/references/classes/LIB_Footprint.md +1298 -1153
- package/skill/references/classes/LIB_LibrariesList.md +361 -329
- package/skill/references/classes/LIB_PanelLibrary.md +855 -855
- package/skill/references/classes/LIB_SelectControl.md +89 -89
- package/skill/references/classes/LIB_SimulationModel.md +807 -821
- package/skill/references/classes/LIB_Symbol.md +1341 -1195
- package/skill/references/classes/PCB_Document.md +1770 -1754
- package/skill/references/classes/PCB_Drc.md +3379 -3375
- package/skill/references/classes/PCB_Event.md +1166 -1081
- package/skill/references/classes/PCB_ImageTool.md +363 -0
- package/skill/references/classes/PCB_Layer.md +1915 -1911
- package/skill/references/classes/PCB_ManufactureData.md +2968 -2968
- package/skill/references/classes/PCB_MathPolygon.md +916 -785
- package/skill/references/classes/PCB_Net.md +1128 -1128
- package/skill/references/classes/PCB_Primitive.md +217 -217
- package/skill/references/classes/PCB_PrimitiveArc.md +820 -894
- package/skill/references/classes/PCB_PrimitiveAttribute.md +635 -717
- package/skill/references/classes/PCB_PrimitiveComponent.md +1050 -1050
- package/skill/references/classes/PCB_PrimitiveDimension.md +789 -833
- package/skill/references/classes/PCB_PrimitiveFill.md +783 -861
- package/skill/references/classes/PCB_PrimitiveImage.md +803 -875
- package/skill/references/classes/PCB_PrimitiveLine.md +787 -858
- package/skill/references/classes/PCB_PrimitiveObject.md +796 -800
- package/skill/references/classes/PCB_PrimitivePad.md +947 -944
- package/skill/references/classes/PCB_PrimitivePolyline.md +744 -819
- package/skill/references/classes/PCB_PrimitivePour.md +808 -845
- package/skill/references/classes/PCB_PrimitivePoured.md +363 -363
- package/skill/references/classes/PCB_PrimitiveRegion.md +765 -799
- package/skill/references/classes/PCB_PrimitiveString.md +828 -910
- package/skill/references/classes/PCB_PrimitiveVia.md +761 -765
- package/skill/references/classes/PCB_RayTracerEngine.md +603 -263
- package/skill/references/classes/PCB_SelectControl.md +495 -495
- package/skill/references/classes/PCB_Tool.md +9 -0
- package/skill/references/classes/PNL_Document.md +83 -83
- package/skill/references/classes/SCH_Document.md +797 -809
- package/skill/references/classes/SCH_Drc.md +246 -242
- package/skill/references/classes/SCH_Event.md +583 -583
- package/skill/references/classes/SCH_ManufactureData.md +1209 -1205
- package/skill/references/classes/SCH_Net.md +200 -200
- package/skill/references/classes/SCH_Netlist.md +191 -191
- package/skill/references/classes/SCH_Primitive.md +337 -337
- package/skill/references/classes/SCH_PrimitiveArc.md +686 -692
- package/skill/references/classes/SCH_PrimitiveAttribute.md +579 -590
- package/skill/references/classes/SCH_PrimitiveBus.md +618 -624
- package/skill/references/classes/SCH_PrimitiveCircle.md +667 -683
- package/skill/references/classes/SCH_PrimitiveComponent.md +2256 -2240
- package/skill/references/classes/SCH_PrimitiveObject.md +666 -666
- package/skill/references/classes/SCH_PrimitivePin.md +737 -754
- package/skill/references/classes/SCH_PrimitivePolygon.md +621 -627
- package/skill/references/classes/SCH_PrimitiveRectangle.md +715 -731
- package/skill/references/classes/SCH_PrimitiveText.md +736 -746
- package/skill/references/classes/SCH_PrimitiveWire.md +701 -703
- package/skill/references/classes/SCH_SelectControl.md +520 -520
- package/skill/references/classes/SCH_SimulationEngine.md +133 -133
- package/skill/references/classes/SCH_Utils.md +121 -121
- package/skill/references/classes/SYS_ClientUrl.md +173 -173
- package/skill/references/classes/SYS_Dialog.md +825 -825
- package/skill/references/classes/SYS_Environment.md +640 -502
- package/skill/references/classes/SYS_ExternalApi.md +246 -0
- package/skill/references/classes/SYS_FileManager.md +1664 -1686
- package/skill/references/classes/SYS_FileSystem.md +1366 -1171
- package/skill/references/classes/SYS_FontManager.md +224 -224
- package/skill/references/classes/SYS_FormatConversion.md +349 -349
- package/skill/references/classes/SYS_HeaderMenu.md +480 -479
- package/skill/references/classes/SYS_Help.md +141 -0
- package/skill/references/classes/SYS_I18n.md +861 -861
- package/skill/references/classes/SYS_IFrame.md +541 -535
- package/skill/references/classes/SYS_LoadingAndProgressBar.md +246 -246
- package/skill/references/classes/SYS_Log.md +422 -424
- package/skill/references/classes/SYS_Math.md +1565 -1565
- package/skill/references/classes/SYS_Message.md +363 -363
- package/skill/references/classes/SYS_MessageBox.md +285 -285
- package/skill/references/classes/SYS_MessageBus.md +1618 -1618
- package/skill/references/classes/SYS_PanelControl.md +696 -696
- package/skill/references/classes/SYS_RightClickMenu.md +175 -175
- package/skill/references/classes/SYS_Setting.md +134 -85
- package/skill/references/classes/SYS_ShortcutKey.md +623 -623
- package/skill/references/classes/SYS_Storage.md +484 -484
- package/skill/references/classes/SYS_Timer.md +447 -447
- package/skill/references/classes/SYS_ToastMessage.md +194 -194
- package/skill/references/classes/SYS_Tool.md +317 -241
- package/skill/references/classes/SYS_Unit.md +594 -594
- package/skill/references/classes/SYS_WebSocket.md +401 -401
- package/skill/references/classes/SYS_Window.md +849 -850
- package/skill/references/enums/EDMT_EditorDocumentType.md +324 -278
- package/skill/references/enums/EDMT_EditorSplitScreenDirection.md +51 -47
- package/skill/references/enums/EDMT_EditorTabEventType.md +68 -62
- package/skill/references/enums/EDMT_IndicatorMarkerType.md +90 -80
- package/skill/references/enums/EDMT_ItemType.md +181 -157
- package/skill/references/enums/EDMT_ProjectCollaborationMode.md +51 -47
- package/skill/references/enums/EDMT_ProjectFileFormat.md +60 -0
- package/skill/references/enums/EDMT_ProjectReadyState.md +82 -0
- package/skill/references/enums/ELIB_DeviceJlcLibraryCategory.md +51 -47
- package/skill/references/enums/ELIB_LibraryType.md +129 -113
- package/skill/references/enums/ELIB_PreviewType.md +77 -69
- package/skill/references/enums/ELIB_SimulationModelType.md +51 -47
- package/skill/references/enums/ELIB_SymbolType.md +142 -124
- package/skill/references/enums/EPCB_AutoRoutingCornerStyle.md +51 -47
- package/skill/references/enums/EPCB_AutoRoutingExistingPrimitiveMode.md +51 -47
- package/skill/references/enums/EPCB_AutoRoutingOptimization.md +51 -47
- package/skill/references/enums/EPCB_DocumentCanvasUpdateCalculationActiveStatus.md +51 -47
- package/skill/references/enums/EPCB_DocumentRatlineCalculatingActiveStatus.md +55 -51
- package/skill/references/enums/EPCB_InactiveLayerDisplayMode.md +64 -58
- package/skill/references/enums/EPCB_LayerColorConfiguration.md +90 -80
- package/skill/references/enums/EPCB_LayerId.md +1169 -881
- package/skill/references/enums/EPCB_LayerStatus.md +64 -58
- package/skill/references/enums/EPCB_LayerType.md +129 -113
- package/skill/references/enums/EPCB_MouseEventType.md +64 -58
- package/skill/references/enums/EPCB_NetEventType.md +64 -58
- package/skill/references/enums/EPCB_PcbPlateType.md +51 -47
- package/skill/references/enums/EPCB_PdfOutputMethod.md +64 -58
- package/skill/references/enums/EPCB_PrimitiveArcInteractiveMode.md +51 -47
- package/skill/references/enums/EPCB_PrimitiveDimensionType.md +64 -58
- package/skill/references/enums/EPCB_PrimitiveEventType.md +64 -58
- package/skill/references/enums/EPCB_PrimitiveFillMode.md +68 -62
- package/skill/references/enums/EPCB_PrimitivePadHeatWeldingConnectionMethod.md +64 -58
- package/skill/references/enums/EPCB_PrimitivePadHoleType.md +64 -58
- package/skill/references/enums/EPCB_PrimitivePadShapeType.md +90 -80
- package/skill/references/enums/EPCB_PrimitivePadType.md +64 -58
- package/skill/references/enums/EPCB_PrimitivePourFillMethod.md +64 -58
- package/skill/references/enums/EPCB_PrimitiveRegionRuleType.md +107 -95
- package/skill/references/enums/EPCB_PrimitiveStringAlignMode.md +142 -124
- package/skill/references/enums/EPCB_PrimitiveType.md +233 -201
- package/skill/references/enums/EPCB_PrimitiveViaType.md +64 -58
- package/skill/references/enums/ESCH_DynamicSimulationEnginePullEventType.md +116 -102
- package/skill/references/enums/ESCH_DynamicSimulationEnginePushEventType.md +90 -80
- package/skill/references/enums/ESCH_ExportDocumentFileType.md +64 -58
- package/skill/references/enums/ESCH_MouseEventType.md +51 -47
- package/skill/references/enums/ESCH_PrimitiveComponentType.md +142 -124
- package/skill/references/enums/ESCH_PrimitiveEventType.md +77 -69
- package/skill/references/enums/ESCH_PrimitiveFillStyle.md +129 -113
- package/skill/references/enums/ESCH_PrimitiveLineType.md +77 -69
- package/skill/references/enums/ESCH_PrimitivePinShape.md +77 -69
- package/skill/references/enums/ESCH_PrimitivePinType.md +168 -146
- package/skill/references/enums/ESCH_PrimitiveTextAlignMode.md +142 -124
- package/skill/references/enums/ESCH_PrimitiveType.md +207 -179
- package/skill/references/enums/ESCH_SimulationNetlistType.md +38 -36
- package/skill/references/enums/ESCH_SpiceSimulationEnginePullEventType.md +51 -47
- package/skill/references/enums/ESCH_SpiceSimulationEnginePushEventType.md +77 -69
- package/skill/references/enums/ESYS_BottomPanelTab.md +94 -80
- package/skill/references/enums/ESYS_HeaderMenuEnvironment.md +181 -157
- package/skill/references/enums/ESYS_ImportProjectBoardOutlineSource.md +55 -51
- package/skill/references/enums/ESYS_ImportProjectImportOption.md +64 -58
- package/skill/references/enums/ESYS_ImportProjectSchematicObjectStyle.md +51 -47
- package/skill/references/enums/ESYS_ImportProjectViaSolderMaskExpansion.md +55 -51
- package/skill/references/enums/ESYS_JobState.md +95 -0
- package/skill/references/enums/ESYS_LeftPanelTab.md +94 -80
- package/skill/references/enums/ESYS_LogType.md +77 -102
- package/skill/references/enums/ESYS_NetlistType.md +129 -113
- package/skill/references/enums/ESYS_PanelPosition.md +69 -0
- package/skill/references/enums/ESYS_PanelTab.md +368 -0
- package/skill/references/enums/ESYS_RightPanelTab.md +237 -201
- package/skill/references/enums/ESYS_ShortcutKeyEffectiveEditorRange.md +220 -190
- package/skill/references/enums/ESYS_ShortcutKeyEffectiveEditorScene.md +103 -91
- package/skill/references/enums/ESYS_StartPageQuickStartItem.md +237 -205
- package/skill/references/enums/ESYS_Theme.md +51 -47
- package/skill/references/enums/ESYS_ToastMessageType.md +90 -80
- package/skill/references/enums/ESYS_Unit.md +116 -102
- package/skill/references/enums/ESYS_WindowEventType.md +64 -47
- package/skill/references/enums/ESYS_WindowOpenTarget.md +51 -47
- package/skill/references/enums/NetportDeviceName.md +146 -146
- package/skill/references/enums/SchToolBarDeviceName.md +278 -278
- package/skill/references/interfaces/BoardProps.md +169 -169
- package/skill/references/interfaces/BorderConfig.md +109 -0
- package/skill/references/interfaces/ButtonProps.md +196 -169
- package/skill/references/interfaces/CellClickInfo.md +142 -0
- package/skill/references/interfaces/CellCoord.md +88 -0
- package/skill/references/interfaces/CheckBoxProps.md +223 -196
- package/skill/references/interfaces/CheckChangeDetail.md +88 -0
- package/skill/references/interfaces/CheckboxEditConfig.md +159 -0
- package/skill/references/interfaces/ClipboardCellData.md +142 -0
- package/skill/references/interfaces/ClipboardConfig.md +115 -0
- package/skill/references/interfaces/ColorPickerProps.md +169 -0
- package/skill/references/interfaces/ColumnDef.md +605 -0
- package/skill/references/interfaces/ColumnEditTrigger.md +57 -0
- package/skill/references/interfaces/ColumnGroupDef.md +192 -0
- package/skill/references/interfaces/ColumnResizeConfig.md +142 -0
- package/skill/references/interfaces/ComponentPropsMap.md +517 -448
- package/skill/references/interfaces/CustomHeaderConfig.md +169 -0
- package/skill/references/interfaces/DialogProps.md +385 -385
- package/skill/references/interfaces/DragSortConfig.md +115 -0
- package/skill/references/interfaces/EditingConfig.md +196 -0
- package/skill/references/interfaces/FilteringConfig.md +250 -0
- package/skill/references/interfaces/FixedColumnConfig.md +88 -0
- package/skill/references/interfaces/FlexItemProps.md +116 -116
- package/skill/references/interfaces/FlexProps.md +224 -224
- package/skill/references/interfaces/GridItemProps.md +143 -143
- package/skill/references/interfaces/GridProps.md +143 -143
- package/skill/references/interfaces/IDMT_BoardItem.md +171 -171
- package/skill/references/interfaces/IDMT_BriefProjectItem.md +171 -171
- package/skill/references/interfaces/IDMT_EditorDocumentItem.md +169 -169
- package/skill/references/interfaces/IDMT_EditorSplitScreenItem.md +173 -173
- package/skill/references/interfaces/IDMT_EditorTabItem.md +169 -169
- package/skill/references/interfaces/IDMT_FolderItem.md +225 -225
- package/skill/references/interfaces/IDMT_IndicatorMarkerShape.md +393 -393
- package/skill/references/interfaces/IDMT_PanelItem.md +144 -144
- package/skill/references/interfaces/IDMT_PcbItem.md +171 -171
- package/skill/references/interfaces/IDMT_ProjectItem.md +143 -143
- package/skill/references/interfaces/IDMT_SchematicItem.md +225 -225
- package/skill/references/interfaces/IDMT_SchematicPageItem.md +198 -198
- package/skill/references/interfaces/IDMT_TeamItem.md +144 -144
- package/skill/references/interfaces/IDMT_WorkspaceItem.md +117 -117
- package/skill/references/interfaces/IDesignPortal.md +103 -103
- package/skill/references/interfaces/ILIB_3DModelItem.md +198 -198
- package/skill/references/interfaces/ILIB_3DModelSearchItem.md +277 -277
- package/skill/references/interfaces/ILIB_CbbItem.md +225 -225
- package/skill/references/interfaces/ILIB_CbbSearchItem.md +277 -277
- package/skill/references/interfaces/ILIB_ClassificationIndex.md +150 -150
- package/skill/references/interfaces/ILIB_ClassificationNode.md +98 -0
- package/skill/references/interfaces/ILIB_DeviceAssociationItem.md +210 -210
- package/skill/references/interfaces/ILIB_DeviceExtendPropertyItem.md +304 -304
- package/skill/references/interfaces/ILIB_DeviceItem.md +279 -279
- package/skill/references/interfaces/ILIB_DevicePropertiesForSearch.md +250 -250
- package/skill/references/interfaces/ILIB_DeviceSearchItem.md +521 -521
- package/skill/references/interfaces/ILIB_ExtendLibrary3DModelFunctions.md +64 -64
- package/skill/references/interfaces/ILIB_ExtendLibraryCbbFunctions.md +93 -99
- package/skill/references/interfaces/ILIB_ExtendLibraryClassificationIndex.md +150 -150
- package/skill/references/interfaces/ILIB_ExtendLibraryDeviceFunctions.md +143 -157
- package/skill/references/interfaces/ILIB_ExtendLibraryFootprintFunctions.md +63 -63
- package/skill/references/interfaces/ILIB_ExtendLibraryFunctions.md +123 -123
- package/skill/references/interfaces/ILIB_ExtendLibraryItem.md +97 -97
- package/skill/references/interfaces/ILIB_ExtendLibraryItemIndex.md +98 -98
- package/skill/references/interfaces/ILIB_ExtendLibrarySearchProperty.md +115 -115
- package/skill/references/interfaces/ILIB_ExtendLibrarySearchResult.md +169 -169
- package/skill/references/interfaces/ILIB_ExtendLibrarySearchResultDataLine.md +234 -234
- package/skill/references/interfaces/ILIB_ExtendLibrarySymbolFunctions.md +91 -105
- package/skill/references/interfaces/ILIB_ExtendLibraryUserIndex.md +96 -96
- package/skill/references/interfaces/ILIB_FootprintItem.md +256 -198
- package/skill/references/interfaces/ILIB_FootprintPropertiesForSearch.md +61 -61
- package/skill/references/interfaces/ILIB_FootprintSearchItem.md +277 -277
- package/skill/references/interfaces/ILIB_LibraryInfo.md +92 -92
- package/skill/references/interfaces/ILIB_LibraryItem.md +115 -115
- package/skill/references/interfaces/ILIB_PanelLibraryItem.md +198 -198
- package/skill/references/interfaces/ILIB_PanelLibrarySearchItem.md +277 -277
- package/skill/references/interfaces/ILIB_RegisterExtendLibraryProps.md +71 -0
- package/skill/references/interfaces/ILIB_SimulationModelItem.md +306 -306
- package/skill/references/interfaces/ILIB_SimulationModelSearchItem.md +304 -304
- package/skill/references/interfaces/ILIB_SymbolItem.md +306 -279
- package/skill/references/interfaces/ILIB_SymbolPropertiesForSearch.md +61 -61
- package/skill/references/interfaces/ILIB_SymbolSearchItem.md +304 -304
- package/skill/references/interfaces/IPCB_AutoLayoutResult.md +169 -169
- package/skill/references/interfaces/IPCB_AutoRoutingProps.md +220 -220
- package/skill/references/interfaces/IPCB_AutoRoutingResult.md +169 -169
- package/skill/references/interfaces/IPCB_BomPropertiesTableColumns.md +169 -169
- package/skill/references/interfaces/IPCB_DifferentialPairItem.md +115 -115
- package/skill/references/interfaces/IPCB_DiscretizeOptions.md +65 -65
- package/skill/references/interfaces/IPCB_DiscretizedPoint.md +88 -88
- package/skill/references/interfaces/IPCB_EqualLengthNetGroupItem.md +115 -115
- package/skill/references/interfaces/IPCB_LayerItem.md +277 -277
- package/skill/references/interfaces/IPCB_NetClassItem.md +115 -115
- package/skill/references/interfaces/IPCB_NetInfo.md +115 -115
- package/skill/references/interfaces/IPCB_PadPairGroupItem.md +88 -88
- package/skill/references/interfaces/IPCB_PadPairMinWireLengthItem.md +88 -88
- package/skill/references/interfaces/IPCB_PhysicalStackingConfiguration.md +115 -115
- package/skill/references/interfaces/IPCB_Primitive.md +218 -218
- package/skill/references/interfaces/IPCB_PrimitiveAPI.md +174 -175
- package/skill/references/interfaces/IPCB_PrimitivePadHeatWelding.md +151 -151
- package/skill/references/interfaces/IPCB_PrimitivePouredPourFill.md +142 -142
- package/skill/references/interfaces/IPCB_PrimitiveSolderMaskAndPasteMaskExpansion.md +154 -154
- package/skill/references/interfaces/IPCB_RayTracerBackgroundConfig.md +223 -0
- package/skill/references/interfaces/IPCB_RayTracerLightConfig.md +412 -0
- package/skill/references/interfaces/IPCB_RayTracerMaterialConfig.md +547 -0
- package/skill/references/interfaces/IPCB_RayTracerPcbMaterialConfig.md +196 -0
- package/skill/references/interfaces/IPCB_RayTracerRenderConfigurations.md +200 -0
- package/skill/references/interfaces/IPCB_RayTracerRendererConfig.md +196 -0
- package/skill/references/interfaces/IPCB_RayTracerSceneElement.md +115 -0
- package/skill/references/interfaces/IPCB_RayTracerSceneElementTransform.md +123 -0
- package/skill/references/interfaces/IPCB_RayTracerTexture.md +88 -0
- package/skill/references/interfaces/IPCB_SubstratePhysicalProperties.md +88 -88
- package/skill/references/interfaces/IRawNet.md +103 -103
- package/skill/references/interfaces/IRawPureSchematic.md +80 -80
- package/skill/references/interfaces/IRawSchematic.md +103 -103
- package/skill/references/interfaces/IRawWire.md +149 -149
- package/skill/references/interfaces/ISCH_DrcError.md +142 -142
- package/skill/references/interfaces/ISCH_DrcErrorPrimitive.md +142 -142
- package/skill/references/interfaces/ISCH_ExportPngResolution.md +94 -94
- package/skill/references/interfaces/ISCH_NetInfo.md +88 -88
- package/skill/references/interfaces/ISCH_Primitive.md +218 -219
- package/skill/references/interfaces/ISCH_PrimitiveAPI.md +174 -175
- package/skill/references/interfaces/ISCH_ProjectNetInfo.md +142 -142
- package/skill/references/interfaces/ISCH_WireInfo.md +169 -169
- package/skill/references/interfaces/ISYS_ComparisonResponse.md +115 -0
- package/skill/references/interfaces/ISYS_ExtensionExternalApiIndex.md +13 -0
- package/skill/references/interfaces/ISYS_ExtensionRegisteredExternalApis.md +13 -0
- package/skill/references/interfaces/ISYS_ExternalApiHelp.md +173 -0
- package/skill/references/interfaces/ISYS_ExternalApiRegistration.md +146 -0
- package/skill/references/interfaces/ISYS_FileSystemFileList.md +169 -169
- package/skill/references/interfaces/ISYS_HeaderMenuSub1MenuItem.md +205 -174
- package/skill/references/interfaces/ISYS_HeaderMenuSub2MenuItem.md +178 -147
- package/skill/references/interfaces/ISYS_HeaderMenuTopMenuItem.md +115 -115
- package/skill/references/interfaces/ISYS_HeaderMenus.md +408 -408
- package/skill/references/interfaces/ISYS_HelpAudienceEntry.md +92 -0
- package/skill/references/interfaces/ISYS_HelpClassSummary.md +205 -0
- package/skill/references/interfaces/ISYS_HelpData.md +92 -0
- package/skill/references/interfaces/ISYS_HelpMethodDetail.md +310 -0
- package/skill/references/interfaces/ISYS_JobHandle.md +65 -0
- package/skill/references/interfaces/ISYS_JobLogEntry.md +142 -0
- package/skill/references/interfaces/ISYS_JobStatus.md +176 -0
- package/skill/references/interfaces/ISYS_LogLine.md +115 -115
- package/skill/references/interfaces/ISYS_MathBBox.md +142 -142
- package/skill/references/interfaces/ISYS_MathPoint.md +88 -88
- package/skill/references/interfaces/ISYS_MathPolygonWithHoles.md +92 -92
- package/skill/references/interfaces/ISYS_MessageBusTask.md +115 -115
- package/skill/references/interfaces/ISYS_MultilingualLanguagesData.md +12 -12
- package/skill/references/interfaces/ISYS_RightClickMenuItem.md +174 -174
- package/skill/references/interfaces/ISYS_ShortcutKeyData.md +169 -169
- package/skill/references/interfaces/ISYS_ShortcutKeyDataWithCallFn.md +62 -62
- package/skill/references/interfaces/ISYS_ShortcutKeyDataWithUserDefinedShortcutKey.md +62 -62
- package/skill/references/interfaces/ISYS_WindowEventListenerRemovableObject.md +109 -109
- package/skill/references/interfaces/IconProps.md +88 -88
- package/skill/references/interfaces/ImageProps.md +115 -115
- package/skill/references/interfaces/InputEditConfig.md +182 -0
- package/skill/references/interfaces/InputProps.md +547 -520
- package/skill/references/interfaces/KeyboardConfig.md +61 -0
- package/skill/references/interfaces/ListChildren.md +223 -223
- package/skill/references/interfaces/ListProps.md +250 -223
- package/skill/references/interfaces/ModalProps.md +358 -358
- package/skill/references/interfaces/NumberEditConfig.md +234 -0
- package/skill/references/interfaces/RadioGroupProps.md +196 -196
- package/skill/references/interfaces/RadioItem.md +115 -115
- package/skill/references/interfaces/RichTableProps.md +1357 -0
- package/skill/references/interfaces/RowMetaConfig.md +142 -0
- package/skill/references/interfaces/ScrollerProps.md +169 -169
- package/skill/references/interfaces/SelectEditConfig.md +211 -0
- package/skill/references/interfaces/SelectListItem.md +142 -142
- package/skill/references/interfaces/SelectOption.md +142 -0
- package/skill/references/interfaces/SelectProps.md +169 -169
- package/skill/references/interfaces/SelectionConfig.md +358 -0
- package/skill/references/interfaces/SliderProps.md +142 -0
- package/skill/references/interfaces/SlotProps.md +88 -88
- package/skill/references/interfaces/SortState.md +88 -0
- package/skill/references/interfaces/SortingConfig.md +169 -0
- package/skill/references/interfaces/StyleProps.md +439 -385
- package/skill/references/interfaces/TextAreaProps.md +196 -196
- package/skill/references/interfaces/TextProps.md +169 -169
- package/skill/references/interfaces/TextareaEditConfig.md +182 -0
- package/skill/references/interfaces/ValidationRule.md +223 -0
- package/skill/references/interfaces/VirtualScrollConfig.md +115 -0
- package/skill/references/types/Align.md +9 -0
- package/skill/references/types/CellContentType.md +9 -0
- package/skill/references/types/ColumnDefOrGroup.md +12 -0
- package/skill/references/types/ColumnEditConfig.md +13 -0
- package/skill/references/types/ColumnType.md +9 -0
- package/skill/references/types/DataChangeType.md +9 -0
- package/skill/references/types/FilterMatchMode.md +9 -0
- package/skill/references/types/RichTableRow.md +12 -0
- package/skill/references/types/Serializable.md +10 -0
- package/skill/references/types/SerializablePrimitive.md +9 -0
- package/skill/references/types/SortOrder.md +9 -0
- package/skill/references/types/TPCB_LayerTypesOfInnerLayer.md +11 -11
- package/skill/references/types/TPCB_LayersInTheSelectable.md +42 -42
- package/skill/references/types/TPCB_LayersOfComponent.md +11 -11
- package/skill/references/types/TPCB_LayersOfCopper.md +15 -15
- package/skill/references/types/TPCB_LayersOfCustom.md +41 -41
- package/skill/references/types/TPCB_LayersOfDimension.md +16 -16
- package/skill/references/types/TPCB_LayersOfFill.md +28 -28
- package/skill/references/types/TPCB_LayersOfImage.md +22 -22
- package/skill/references/types/TPCB_LayersOfInner.md +41 -41
- package/skill/references/types/TPCB_LayersOfLine.md +25 -25
- package/skill/references/types/TPCB_LayersOfObject.md +12 -12
- package/skill/references/types/TPCB_LayersOfPad.md +11 -11
- package/skill/references/types/TPCB_LayersOfRegion.md +11 -11
- package/skill/references/types/TPCB_NumberOfCopperLayers.md +9 -9
- package/skill/references/types/TPCB_PolygonSourceArray.md +85 -83
- package/skill/references/types/TPCB_PrimitiveDimensionCoordinateSet.md +66 -66
- package/skill/references/types/TPCB_PrimitivePadHole.md +30 -30
- package/skill/references/types/TPCB_PrimitivePadShape.md +61 -61
- package/skill/references/types/TPCB_PrimitiveSpecialPadShape.md +19 -19
- package/skill/references/types/TSYS_ComparisonErrorCode.md +15 -0
- package/skill/references/types/TSYS_LanguageKeyValuePairs.md +13 -0
- package/skill/references/types/TSYS_MathPolygonGroup.md +15 -15
- package/skill/references/types/TSYS_MathPolygonInput.md +20 -20
- package/skill/references/types/TSYS_ShortcutKeys.md +96 -96
- package/skill/user-guide/using-extension.md +47 -47
- package/src/json-gen.test.js +430 -0
- package/skill/guide/ancillary-projects/pro-api-sdk.md +0 -1
- package/skill/references/interfaces/ISYS_PcbComparisonResponse.md +0 -115
- package/skill/references/types/ISYS_LanguageKeyValuePairs.md +0 -13
- package/skill/references/types/TSYS_PcbComparisonErrorCode.md +0 -10
|
@@ -1,957 +1,957 @@
|
|
|
1
|
-
# LIB\_Cbb class
|
|
2
|
-
|
|
3
|
-
Comprehensive library / reuse block class
|
|
4
|
-
|
|
5
|
-
## Signature
|
|
6
|
-
|
|
7
|
-
```typescript
|
|
8
|
-
class LIB_Cbb
|
|
9
|
-
```
|
|
10
|
-
|
|
11
|
-
## Methods
|
|
12
|
-
|
|
13
|
-
<table><thead><tr><th>
|
|
14
|
-
|
|
15
|
-
Method
|
|
16
|
-
|
|
17
|
-
</th><th>
|
|
18
|
-
|
|
19
|
-
Modifiers
|
|
20
|
-
|
|
21
|
-
</th><th>
|
|
22
|
-
|
|
23
|
-
Description
|
|
24
|
-
|
|
25
|
-
</th></tr></thead>
|
|
26
|
-
<tbody><tr><td>
|
|
27
|
-
|
|
28
|
-
[copy(cbbUuid, libraryUuid, targetLibraryUuid, targetClassification, newCbbName)](./LIB_Cbb.md)
|
|
29
|
-
|
|
30
|
-
</td><td>
|
|
31
|
-
|
|
32
|
-
</td><td>
|
|
33
|
-
|
|
34
|
-
**_(BETA)_** Copy Reuse block
|
|
35
|
-
|
|
36
|
-
</td></tr>
|
|
37
|
-
<tr><td>
|
|
38
|
-
|
|
39
|
-
[create(libraryUuid, cbbName, classification, description)](./LIB_Cbb.md)
|
|
40
|
-
|
|
41
|
-
</td><td>
|
|
42
|
-
|
|
43
|
-
</td><td>
|
|
44
|
-
|
|
45
|
-
**_(BETA)_** Create Reuse block
|
|
46
|
-
|
|
47
|
-
</td></tr>
|
|
48
|
-
<tr><td>
|
|
49
|
-
|
|
50
|
-
[delete(cbbUuid, libraryUuid)](./LIB_Cbb.md)
|
|
51
|
-
|
|
52
|
-
</td><td>
|
|
53
|
-
|
|
54
|
-
</td><td>
|
|
55
|
-
|
|
56
|
-
**_(BETA)_** Delete Reuse block
|
|
57
|
-
|
|
58
|
-
</td></tr>
|
|
59
|
-
<tr><td>
|
|
60
|
-
|
|
61
|
-
[get(cbbUuid, libraryUuid)](./LIB_Cbb.md)
|
|
62
|
-
|
|
63
|
-
</td><td>
|
|
64
|
-
|
|
65
|
-
</td><td>
|
|
66
|
-
|
|
67
|
-
**_(BETA)_** Get all properties of the reuse block
|
|
68
|
-
|
|
69
|
-
</td></tr>
|
|
70
|
-
<tr><td>
|
|
71
|
-
|
|
72
|
-
[modify(cbbUuid, libraryUuid, cbbName, classification, description)](./LIB_Cbb.md)
|
|
73
|
-
|
|
74
|
-
</td><td>
|
|
75
|
-
|
|
76
|
-
</td><td>
|
|
77
|
-
|
|
78
|
-
**_(BETA)_** Modify Reuse block
|
|
79
|
-
|
|
80
|
-
</td></tr>
|
|
81
|
-
<tr><td>
|
|
82
|
-
|
|
83
|
-
[openProjectInEditor(cbbUuid, libraryUuid)](./LIB_Cbb.md)
|
|
84
|
-
|
|
85
|
-
</td><td>
|
|
86
|
-
|
|
87
|
-
</td><td>
|
|
88
|
-
|
|
89
|
-
**_(BETA)_** Open in the editor reuse block project
|
|
90
|
-
|
|
91
|
-
</td></tr>
|
|
92
|
-
<tr><td>
|
|
93
|
-
|
|
94
|
-
[openSymbolInEditor(cbbUuid, libraryUuid, splitScreenId)](./LIB_Cbb.md)
|
|
95
|
-
|
|
96
|
-
</td><td>
|
|
97
|
-
|
|
98
|
-
</td><td>
|
|
99
|
-
|
|
100
|
-
**_(BETA)_** Open in the editor reuse block symbol
|
|
101
|
-
|
|
102
|
-
</td></tr>
|
|
103
|
-
<tr><td>
|
|
104
|
-
|
|
105
|
-
[search(key, libraryUuid, classification, itemsOfPage, page)](./LIB_Cbb.md)
|
|
106
|
-
|
|
107
|
-
</td><td>
|
|
108
|
-
|
|
109
|
-
</td><td>
|
|
110
|
-
|
|
111
|
-
**_(BETA)_** Search reuse block
|
|
112
|
-
|
|
113
|
-
</td></tr>
|
|
114
|
-
</tbody></table>
|
|
115
|
-
|
|
116
|
-
---
|
|
117
|
-
|
|
118
|
-
## 方法详情
|
|
119
|
-
|
|
120
|
-
### copy
|
|
121
|
-
|
|
122
|
-
# LIB\_Cbb.copy() method
|
|
123
|
-
|
|
124
|
-
> This API is provided as a beta preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
|
|
125
|
-
|
|
126
|
-
Copy Reuse block
|
|
127
|
-
|
|
128
|
-
## Signature
|
|
129
|
-
|
|
130
|
-
```typescript
|
|
131
|
-
function copy(
|
|
132
|
-
cbbUuid: string,
|
|
133
|
-
libraryUuid: string,
|
|
134
|
-
targetLibraryUuid: string,
|
|
135
|
-
targetClassification?: ILIB_ClassificationIndex | Array<string>,
|
|
136
|
-
newCbbName?: string,
|
|
137
|
-
): Promise<string | undefined>;
|
|
138
|
-
```
|
|
139
|
-
|
|
140
|
-
## Parameters
|
|
141
|
-
|
|
142
|
-
<table><thead><tr><th>
|
|
143
|
-
|
|
144
|
-
Parameter
|
|
145
|
-
|
|
146
|
-
</th><th>
|
|
147
|
-
|
|
148
|
-
Type
|
|
149
|
-
|
|
150
|
-
</th><th>
|
|
151
|
-
|
|
152
|
-
Description
|
|
153
|
-
|
|
154
|
-
</th></tr></thead>
|
|
155
|
-
<tbody><tr><td>
|
|
156
|
-
|
|
157
|
-
cbbUuid
|
|
158
|
-
|
|
159
|
-
</td><td>
|
|
160
|
-
|
|
161
|
-
string
|
|
162
|
-
|
|
163
|
-
</td><td>
|
|
164
|
-
|
|
165
|
-
Reuse block UUID
|
|
166
|
-
|
|
167
|
-
</td></tr>
|
|
168
|
-
<tr><td>
|
|
169
|
-
|
|
170
|
-
libraryUuid
|
|
171
|
-
|
|
172
|
-
</td><td>
|
|
173
|
-
|
|
174
|
-
string
|
|
175
|
-
|
|
176
|
-
</td><td>
|
|
177
|
-
|
|
178
|
-
Library UUID, you can use [LIB\_LibrariesList](./LIB_LibrariesList.md) APIs in
|
|
179
|
-
|
|
180
|
-
</td></tr>
|
|
181
|
-
<tr><td>
|
|
182
|
-
|
|
183
|
-
targetLibraryUuid
|
|
184
|
-
|
|
185
|
-
</td><td>
|
|
186
|
-
|
|
187
|
-
string
|
|
188
|
-
|
|
189
|
-
</td><td>
|
|
190
|
-
|
|
191
|
-
Target library UUID
|
|
192
|
-
|
|
193
|
-
</td></tr>
|
|
194
|
-
<tr><td>
|
|
195
|
-
|
|
196
|
-
targetClassification
|
|
197
|
-
|
|
198
|
-
</td><td>
|
|
199
|
-
|
|
200
|
-
[ILIB\_ClassificationIndex](../interfaces/ILIB_ClassificationIndex.md) \| Array<string>
|
|
201
|
-
|
|
202
|
-
</td><td>
|
|
203
|
-
|
|
204
|
-
_(Optional)_ Classification in the target library
|
|
205
|
-
|
|
206
|
-
</td></tr>
|
|
207
|
-
<tr><td>
|
|
208
|
-
|
|
209
|
-
newCbbName
|
|
210
|
-
|
|
211
|
-
</td><td>
|
|
212
|
-
|
|
213
|
-
string
|
|
214
|
-
|
|
215
|
-
</td><td>
|
|
216
|
-
|
|
217
|
-
_(Optional)_ New reuse block name. If a reuse block with the same name exists in the target library, the copy will fail
|
|
218
|
-
|
|
219
|
-
</td></tr>
|
|
220
|
-
</tbody></table>
|
|
221
|
-
|
|
222
|
-
## Returns
|
|
223
|
-
|
|
224
|
-
Promise<string \| undefined>
|
|
225
|
-
|
|
226
|
-
UUID of the new reuse block in the target library
|
|
227
|
-
|
|
228
|
-
## Example
|
|
229
|
-
|
|
230
|
-
```javascript
|
|
231
|
-
// 1. 获取系统库与个人库 UUID
|
|
232
|
-
const systemLib = await eda.lib_LibrariesList.getSystemLibraryUuid();
|
|
233
|
-
const personalLib = await eda.lib_LibrariesList.getPersonalLibraryUuid();
|
|
234
|
-
|
|
235
|
-
// 2. 从系统库找一个复用模块作为复制来源
|
|
236
|
-
const results = await eda.lib_Cbb.search('', systemLib, undefined, 1);
|
|
237
|
-
const source = results[0];
|
|
238
|
-
|
|
239
|
-
// 3. 复制到个人库,指定新名称避免同名冲突(分类传 [] = 不分类)
|
|
240
|
-
const newName = `嘉立创示例_复制_${Date.now()}`;
|
|
241
|
-
const copiedUuid = await eda.lib_Cbb.copy(source.uuid, systemLib, personalLib, [], newName);
|
|
242
|
-
|
|
243
|
-
// 创建类保留现场(复制品留在个人库中供观察)
|
|
244
|
-
|
|
245
|
-
console.log('source:', source.name, source.uuid);
|
|
246
|
-
console.log('copiedUuid:', copiedUuid);
|
|
247
|
-
console.log('newName:', newName);
|
|
248
|
-
```
|
|
249
|
-
|
|
250
|
-
### create
|
|
251
|
-
|
|
252
|
-
# LIB\_Cbb.create() method
|
|
253
|
-
|
|
254
|
-
> This API is provided as a beta preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
|
|
255
|
-
|
|
256
|
-
Create Reuse block
|
|
257
|
-
|
|
258
|
-
## Signature
|
|
259
|
-
|
|
260
|
-
```typescript
|
|
261
|
-
function create(
|
|
262
|
-
libraryUuid: string,
|
|
263
|
-
cbbName: string,
|
|
264
|
-
classification?: ILIB_ClassificationIndex | Array<string>,
|
|
265
|
-
description?: string,
|
|
266
|
-
): Promise<string | undefined>;
|
|
267
|
-
```
|
|
268
|
-
|
|
269
|
-
## Parameters
|
|
270
|
-
|
|
271
|
-
<table><thead><tr><th>
|
|
272
|
-
|
|
273
|
-
Parameter
|
|
274
|
-
|
|
275
|
-
</th><th>
|
|
276
|
-
|
|
277
|
-
Type
|
|
278
|
-
|
|
279
|
-
</th><th>
|
|
280
|
-
|
|
281
|
-
Description
|
|
282
|
-
|
|
283
|
-
</th></tr></thead>
|
|
284
|
-
<tbody><tr><td>
|
|
285
|
-
|
|
286
|
-
libraryUuid
|
|
287
|
-
|
|
288
|
-
</td><td>
|
|
289
|
-
|
|
290
|
-
string
|
|
291
|
-
|
|
292
|
-
</td><td>
|
|
293
|
-
|
|
294
|
-
Library UUID, you can use [LIB\_LibrariesList](./LIB_LibrariesList.md) APIs in
|
|
295
|
-
|
|
296
|
-
</td></tr>
|
|
297
|
-
<tr><td>
|
|
298
|
-
|
|
299
|
-
cbbName
|
|
300
|
-
|
|
301
|
-
</td><td>
|
|
302
|
-
|
|
303
|
-
string
|
|
304
|
-
|
|
305
|
-
</td><td>
|
|
306
|
-
|
|
307
|
-
Reuse block name
|
|
308
|
-
|
|
309
|
-
</td></tr>
|
|
310
|
-
<tr><td>
|
|
311
|
-
|
|
312
|
-
classification
|
|
313
|
-
|
|
314
|
-
</td><td>
|
|
315
|
-
|
|
316
|
-
[ILIB\_ClassificationIndex](../interfaces/ILIB_ClassificationIndex.md) \| Array<string>
|
|
317
|
-
|
|
318
|
-
</td><td>
|
|
319
|
-
|
|
320
|
-
_(Optional)_ Classification
|
|
321
|
-
|
|
322
|
-
</td></tr>
|
|
323
|
-
<tr><td>
|
|
324
|
-
|
|
325
|
-
description
|
|
326
|
-
|
|
327
|
-
</td><td>
|
|
328
|
-
|
|
329
|
-
string
|
|
330
|
-
|
|
331
|
-
</td><td>
|
|
332
|
-
|
|
333
|
-
_(Optional)_ Description
|
|
334
|
-
|
|
335
|
-
</td></tr>
|
|
336
|
-
</tbody></table>
|
|
337
|
-
|
|
338
|
-
## Returns
|
|
339
|
-
|
|
340
|
-
Promise<string \| undefined>
|
|
341
|
-
|
|
342
|
-
Reuse block UUID
|
|
343
|
-
|
|
344
|
-
## Example
|
|
345
|
-
|
|
346
|
-
```javascript
|
|
347
|
-
// 1. 获取个人库 UUID
|
|
348
|
-
const libraryUuid = await eda.lib_LibrariesList.getPersonalLibraryUuid();
|
|
349
|
-
|
|
350
|
-
// 2. 在个人库创建复用模块(分类传空数组 = 不分类)
|
|
351
|
-
const cbbName = `嘉立创示例_新建模块_${Date.now()}`;
|
|
352
|
-
const cbbUuid = await eda.lib_Cbb.create(libraryUuid, cbbName, [], '示例描述');
|
|
353
|
-
|
|
354
|
-
// 创建类保留现场
|
|
355
|
-
|
|
356
|
-
console.log('libraryUuid:', libraryUuid);
|
|
357
|
-
console.log('cbbName:', cbbName);
|
|
358
|
-
console.log('cbbUuid:', cbbUuid);
|
|
359
|
-
```
|
|
360
|
-
|
|
361
|
-
### delete
|
|
362
|
-
|
|
363
|
-
# LIB\_Cbb.delete() method
|
|
364
|
-
|
|
365
|
-
> This API is provided as a beta preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
|
|
366
|
-
|
|
367
|
-
Delete Reuse block
|
|
368
|
-
|
|
369
|
-
## Signature
|
|
370
|
-
|
|
371
|
-
```typescript
|
|
372
|
-
function delete(cbbUuid: string, libraryUuid: string): Promise<boolean>;
|
|
373
|
-
```
|
|
374
|
-
|
|
375
|
-
## Parameters
|
|
376
|
-
|
|
377
|
-
<table><thead><tr><th>
|
|
378
|
-
|
|
379
|
-
Parameter
|
|
380
|
-
|
|
381
|
-
</th><th>
|
|
382
|
-
|
|
383
|
-
Type
|
|
384
|
-
|
|
385
|
-
</th><th>
|
|
386
|
-
|
|
387
|
-
Description
|
|
388
|
-
|
|
389
|
-
</th></tr></thead>
|
|
390
|
-
<tbody><tr><td>
|
|
391
|
-
|
|
392
|
-
cbbUuid
|
|
393
|
-
|
|
394
|
-
</td><td>
|
|
395
|
-
|
|
396
|
-
string
|
|
397
|
-
|
|
398
|
-
</td><td>
|
|
399
|
-
|
|
400
|
-
Reuse block UUID
|
|
401
|
-
|
|
402
|
-
</td></tr>
|
|
403
|
-
<tr><td>
|
|
404
|
-
|
|
405
|
-
libraryUuid
|
|
406
|
-
|
|
407
|
-
</td><td>
|
|
408
|
-
|
|
409
|
-
string
|
|
410
|
-
|
|
411
|
-
</td><td>
|
|
412
|
-
|
|
413
|
-
Library UUID, you can use [LIB\_LibrariesList](./LIB_LibrariesList.md) APIs in
|
|
414
|
-
|
|
415
|
-
</td></tr>
|
|
416
|
-
</tbody></table>
|
|
417
|
-
|
|
418
|
-
## Returns
|
|
419
|
-
|
|
420
|
-
Promise<boolean>
|
|
421
|
-
|
|
422
|
-
Whether the operation is successful
|
|
423
|
-
|
|
424
|
-
## Example
|
|
425
|
-
|
|
426
|
-
```javascript
|
|
427
|
-
// 1. 获取系统库与个人库 UUID
|
|
428
|
-
const systemLib = await eda.lib_LibrariesList.getSystemLibraryUuid();
|
|
429
|
-
const personalLib = await eda.lib_LibrariesList.getPersonalLibraryUuid();
|
|
430
|
-
|
|
431
|
-
// 2. 复制一个系统库模块到个人库作为删除对象
|
|
432
|
-
const results = await eda.lib_Cbb.search('', systemLib, undefined, 1);
|
|
433
|
-
const source = results[0];
|
|
434
|
-
const cbbUuid = await eda.lib_Cbb.copy(source.uuid, systemLib, personalLib, [], `嘉立创示例_删除_${Date.now()}`);
|
|
435
|
-
|
|
436
|
-
// 3. 删除复制品
|
|
437
|
-
const deleted = await eda.lib_Cbb.delete(cbbUuid, personalLib);
|
|
438
|
-
|
|
439
|
-
console.log('cbbUuid:', cbbUuid);
|
|
440
|
-
console.log('deleted:', deleted);
|
|
441
|
-
```
|
|
442
|
-
|
|
443
|
-
### get
|
|
444
|
-
|
|
445
|
-
# LIB\_Cbb.get() method
|
|
446
|
-
|
|
447
|
-
> This API is provided as a beta preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
|
|
448
|
-
|
|
449
|
-
Get all properties of the reuse block
|
|
450
|
-
|
|
451
|
-
## Signature
|
|
452
|
-
|
|
453
|
-
```typescript
|
|
454
|
-
function get(cbbUuid: string, libraryUuid?: string): Promise<ILIB_CbbItem | undefined>;
|
|
455
|
-
```
|
|
456
|
-
|
|
457
|
-
## Parameters
|
|
458
|
-
|
|
459
|
-
<table><thead><tr><th>
|
|
460
|
-
|
|
461
|
-
Parameter
|
|
462
|
-
|
|
463
|
-
</th><th>
|
|
464
|
-
|
|
465
|
-
Type
|
|
466
|
-
|
|
467
|
-
</th><th>
|
|
468
|
-
|
|
469
|
-
Description
|
|
470
|
-
|
|
471
|
-
</th></tr></thead>
|
|
472
|
-
<tbody><tr><td>
|
|
473
|
-
|
|
474
|
-
cbbUuid
|
|
475
|
-
|
|
476
|
-
</td><td>
|
|
477
|
-
|
|
478
|
-
string
|
|
479
|
-
|
|
480
|
-
</td><td>
|
|
481
|
-
|
|
482
|
-
Reuse block UUID
|
|
483
|
-
|
|
484
|
-
</td></tr>
|
|
485
|
-
<tr><td>
|
|
486
|
-
|
|
487
|
-
libraryUuid
|
|
488
|
-
|
|
489
|
-
</td><td>
|
|
490
|
-
|
|
491
|
-
string
|
|
492
|
-
|
|
493
|
-
</td><td>
|
|
494
|
-
|
|
495
|
-
_(Optional)_ Library UUID, default is system library, you can use [LIB\_LibrariesList](./LIB_LibrariesList.md) APIs in
|
|
496
|
-
|
|
497
|
-
</td></tr>
|
|
498
|
-
</tbody></table>
|
|
499
|
-
|
|
500
|
-
## Returns
|
|
501
|
-
|
|
502
|
-
Promise<[ILIB\_CbbItem](../interfaces/ILIB_CbbItem.md) \| undefined>
|
|
503
|
-
|
|
504
|
-
Reuse block property
|
|
505
|
-
|
|
506
|
-
### modify
|
|
507
|
-
|
|
508
|
-
# LIB\_Cbb.modify() method
|
|
509
|
-
|
|
510
|
-
> This API is provided as a beta preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
|
|
511
|
-
|
|
512
|
-
Modify Reuse block
|
|
513
|
-
|
|
514
|
-
## Signature
|
|
515
|
-
|
|
516
|
-
```typescript
|
|
517
|
-
function modify(
|
|
518
|
-
cbbUuid: string,
|
|
519
|
-
libraryUuid: string,
|
|
520
|
-
cbbName?: string,
|
|
521
|
-
classification?: ILIB_ClassificationIndex | Array<string> | null,
|
|
522
|
-
description?: string | null,
|
|
523
|
-
): Promise<boolean>;
|
|
524
|
-
```
|
|
525
|
-
|
|
526
|
-
## Parameters
|
|
527
|
-
|
|
528
|
-
<table><thead><tr><th>
|
|
529
|
-
|
|
530
|
-
Parameter
|
|
531
|
-
|
|
532
|
-
</th><th>
|
|
533
|
-
|
|
534
|
-
Type
|
|
535
|
-
|
|
536
|
-
</th><th>
|
|
537
|
-
|
|
538
|
-
Description
|
|
539
|
-
|
|
540
|
-
</th></tr></thead>
|
|
541
|
-
<tbody><tr><td>
|
|
542
|
-
|
|
543
|
-
cbbUuid
|
|
544
|
-
|
|
545
|
-
</td><td>
|
|
546
|
-
|
|
547
|
-
string
|
|
548
|
-
|
|
549
|
-
</td><td>
|
|
550
|
-
|
|
551
|
-
Reuse block UUID
|
|
552
|
-
|
|
553
|
-
</td></tr>
|
|
554
|
-
<tr><td>
|
|
555
|
-
|
|
556
|
-
libraryUuid
|
|
557
|
-
|
|
558
|
-
</td><td>
|
|
559
|
-
|
|
560
|
-
string
|
|
561
|
-
|
|
562
|
-
</td><td>
|
|
563
|
-
|
|
564
|
-
Library UUID, you can use [LIB\_LibrariesList](./LIB_LibrariesList.md) APIs in
|
|
565
|
-
|
|
566
|
-
</td></tr>
|
|
567
|
-
<tr><td>
|
|
568
|
-
|
|
569
|
-
cbbName
|
|
570
|
-
|
|
571
|
-
</td><td>
|
|
572
|
-
|
|
573
|
-
string
|
|
574
|
-
|
|
575
|
-
</td><td>
|
|
576
|
-
|
|
577
|
-
_(Optional)_ Reuse block name
|
|
578
|
-
|
|
579
|
-
</td></tr>
|
|
580
|
-
<tr><td>
|
|
581
|
-
|
|
582
|
-
classification
|
|
583
|
-
|
|
584
|
-
</td><td>
|
|
585
|
-
|
|
586
|
-
[ILIB\_ClassificationIndex](../interfaces/ILIB_ClassificationIndex.md) \| Array<string> \| null
|
|
587
|
-
|
|
588
|
-
</td><td>
|
|
589
|
-
|
|
590
|
-
_(Optional)_ Classification
|
|
591
|
-
|
|
592
|
-
</td></tr>
|
|
593
|
-
<tr><td>
|
|
594
|
-
|
|
595
|
-
description
|
|
596
|
-
|
|
597
|
-
</td><td>
|
|
598
|
-
|
|
599
|
-
string \| null
|
|
600
|
-
|
|
601
|
-
</td><td>
|
|
602
|
-
|
|
603
|
-
_(Optional)_ Description
|
|
604
|
-
|
|
605
|
-
</td></tr>
|
|
606
|
-
</tbody></table>
|
|
607
|
-
|
|
608
|
-
## Returns
|
|
609
|
-
|
|
610
|
-
Promise<boolean>
|
|
611
|
-
|
|
612
|
-
Whether the operation is successful
|
|
613
|
-
|
|
614
|
-
## Remarks
|
|
615
|
-
|
|
616
|
-
If you want to clear certain properties, set their values to `null`
|
|
617
|
-
|
|
618
|
-
## Example
|
|
619
|
-
|
|
620
|
-
```javascript
|
|
621
|
-
// 1. 获取系统库与个人库 UUID
|
|
622
|
-
const systemLib = await eda.lib_LibrariesList.getSystemLibraryUuid();
|
|
623
|
-
const personalLib = await eda.lib_LibrariesList.getPersonalLibraryUuid();
|
|
624
|
-
|
|
625
|
-
// 2. 复制一个系统库模块到个人库作为修改对象
|
|
626
|
-
const results = await eda.lib_Cbb.search('', systemLib, undefined, 1);
|
|
627
|
-
const source = results[0];
|
|
628
|
-
const cbbUuid = await eda.lib_Cbb.copy(source.uuid, systemLib, personalLib, [], `嘉立创示例_修改_${Date.now()}`);
|
|
629
|
-
|
|
630
|
-
// 3. 修改名称和描述(分类保持不变传 [])
|
|
631
|
-
const newName = `嘉立创示例_重命名_${Date.now()}`;
|
|
632
|
-
const modified = await eda.lib_Cbb.modify(cbbUuid, personalLib, newName, [], '修改后的描述');
|
|
633
|
-
|
|
634
|
-
// 修改类保留现场
|
|
635
|
-
|
|
636
|
-
console.log('cbbUuid:', cbbUuid);
|
|
637
|
-
console.log('modified:', modified);
|
|
638
|
-
console.log('newName:', newName);
|
|
639
|
-
```
|
|
640
|
-
|
|
641
|
-
### openprojectineditor
|
|
642
|
-
|
|
643
|
-
# LIB\_Cbb.openProjectInEditor() method
|
|
644
|
-
|
|
645
|
-
> This API is provided as a beta preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
|
|
646
|
-
|
|
647
|
-
Open in the editor reuse block project
|
|
648
|
-
|
|
649
|
-
## Signature
|
|
650
|
-
|
|
651
|
-
```typescript
|
|
652
|
-
function openProjectInEditor(cbbUuid: string, libraryUuid: string): Promise<boolean>;
|
|
653
|
-
```
|
|
654
|
-
|
|
655
|
-
## Parameters
|
|
656
|
-
|
|
657
|
-
<table><thead><tr><th>
|
|
658
|
-
|
|
659
|
-
Parameter
|
|
660
|
-
|
|
661
|
-
</th><th>
|
|
662
|
-
|
|
663
|
-
Type
|
|
664
|
-
|
|
665
|
-
</th><th>
|
|
666
|
-
|
|
667
|
-
Description
|
|
668
|
-
|
|
669
|
-
</th></tr></thead>
|
|
670
|
-
<tbody><tr><td>
|
|
671
|
-
|
|
672
|
-
cbbUuid
|
|
673
|
-
|
|
674
|
-
</td><td>
|
|
675
|
-
|
|
676
|
-
string
|
|
677
|
-
|
|
678
|
-
</td><td>
|
|
679
|
-
|
|
680
|
-
Reuse block UUID
|
|
681
|
-
|
|
682
|
-
</td></tr>
|
|
683
|
-
<tr><td>
|
|
684
|
-
|
|
685
|
-
libraryUuid
|
|
686
|
-
|
|
687
|
-
</td><td>
|
|
688
|
-
|
|
689
|
-
string
|
|
690
|
-
|
|
691
|
-
</td><td>
|
|
692
|
-
|
|
693
|
-
Library UUID, you can use [LIB\_LibrariesList](./LIB_LibrariesList.md) APIs in
|
|
694
|
-
|
|
695
|
-
</td></tr>
|
|
696
|
-
</tbody></table>
|
|
697
|
-
|
|
698
|
-
## Returns
|
|
699
|
-
|
|
700
|
-
Promise<boolean>
|
|
701
|
-
|
|
702
|
-
## Remarks
|
|
703
|
-
|
|
704
|
-
This operation will open the module project in the EDA front end. If another project was previously opened with unsaved changes, executing this operation will directly lose all unsaved data
|
|
705
|
-
|
|
706
|
-
## Example
|
|
707
|
-
|
|
708
|
-
```javascript
|
|
709
|
-
// 1. 记录当前工程,便于演示结束后恢复
|
|
710
|
-
const projectInfo = await eda.dmt_Project.getCurrentProjectInfo();
|
|
711
|
-
|
|
712
|
-
// 2. 复制一个系统库模块到个人库作为打开对象
|
|
713
|
-
const systemLib = await eda.lib_LibrariesList.getSystemLibraryUuid();
|
|
714
|
-
const personalLib = await eda.lib_LibrariesList.getPersonalLibraryUuid();
|
|
715
|
-
const results = await eda.lib_Cbb.search('', systemLib, undefined, 1);
|
|
716
|
-
const source = results[0];
|
|
717
|
-
const cbbUuid = await eda.lib_Cbb.copy(source.uuid, systemLib, personalLib, [], `嘉立创示例_打开工程_${Date.now()}`);
|
|
718
|
-
|
|
719
|
-
// 3. 在编辑器打开模块工程
|
|
720
|
-
const opened = await eda.lib_Cbb.openProjectInEditor(cbbUuid, personalLib);
|
|
721
|
-
|
|
722
|
-
// 4. 恢复原来打开的工程
|
|
723
|
-
await new Promise(r => setTimeout(r, 1000));
|
|
724
|
-
await eda.dmt_Project.openProject(projectInfo.uuid);
|
|
725
|
-
|
|
726
|
-
console.log('source:', source.name, source.uuid);
|
|
727
|
-
console.log('opened:', opened);
|
|
728
|
-
console.log('restored:', projectInfo.uuid);
|
|
729
|
-
```
|
|
730
|
-
|
|
731
|
-
### opensymbolineditor
|
|
732
|
-
|
|
733
|
-
# LIB\_Cbb.openSymbolInEditor() method
|
|
734
|
-
|
|
735
|
-
> This API is provided as a beta preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
|
|
736
|
-
|
|
737
|
-
Open in the editor reuse block symbol
|
|
738
|
-
|
|
739
|
-
## Signature
|
|
740
|
-
|
|
741
|
-
```typescript
|
|
742
|
-
function openSymbolInEditor(
|
|
743
|
-
cbbUuid: string,
|
|
744
|
-
libraryUuid: string,
|
|
745
|
-
splitScreenId?: string,
|
|
746
|
-
): Promise<string | undefined>;
|
|
747
|
-
```
|
|
748
|
-
|
|
749
|
-
## Parameters
|
|
750
|
-
|
|
751
|
-
<table><thead><tr><th>
|
|
752
|
-
|
|
753
|
-
Parameter
|
|
754
|
-
|
|
755
|
-
</th><th>
|
|
756
|
-
|
|
757
|
-
Type
|
|
758
|
-
|
|
759
|
-
</th><th>
|
|
760
|
-
|
|
761
|
-
Description
|
|
762
|
-
|
|
763
|
-
</th></tr></thead>
|
|
764
|
-
<tbody><tr><td>
|
|
765
|
-
|
|
766
|
-
cbbUuid
|
|
767
|
-
|
|
768
|
-
</td><td>
|
|
769
|
-
|
|
770
|
-
string
|
|
771
|
-
|
|
772
|
-
</td><td>
|
|
773
|
-
|
|
774
|
-
Reuse block UUID
|
|
775
|
-
|
|
776
|
-
</td></tr>
|
|
777
|
-
<tr><td>
|
|
778
|
-
|
|
779
|
-
libraryUuid
|
|
780
|
-
|
|
781
|
-
</td><td>
|
|
782
|
-
|
|
783
|
-
string
|
|
784
|
-
|
|
785
|
-
</td><td>
|
|
786
|
-
|
|
787
|
-
Library UUID, you can use [LIB\_LibrariesList](./LIB_LibrariesList.md) APIs in
|
|
788
|
-
|
|
789
|
-
</td></tr>
|
|
790
|
-
<tr><td>
|
|
791
|
-
|
|
792
|
-
splitScreenId
|
|
793
|
-
|
|
794
|
-
</td><td>
|
|
795
|
-
|
|
796
|
-
string
|
|
797
|
-
|
|
798
|
-
</td><td>
|
|
799
|
-
|
|
800
|
-
_(Optional)_ Split screen ID. If not filled in, it opens in the split screen with the last input focus by default. It can be obtained using the APIs in [DMT\_EditorControl](./DMT_EditorControl.md)
|
|
801
|
-
|
|
802
|
-
</td></tr>
|
|
803
|
-
</tbody></table>
|
|
804
|
-
|
|
805
|
-
## Returns
|
|
806
|
-
|
|
807
|
-
Promise<string \| undefined>
|
|
808
|
-
|
|
809
|
-
Tab ID, corresponding to [IDMT\_EditorTabItem.tabId](../interfaces/IDMT_EditorTabItem.md)<!-- -->. You can use [DMT\_EditorControl.getSplitScreenIdByTabId()](./DMT_EditorControl.md) to get the split screen ID
|
|
810
|
-
|
|
811
|
-
## Example
|
|
812
|
-
|
|
813
|
-
```javascript
|
|
814
|
-
// 1. 记录当前工程,便于演示结束后恢复
|
|
815
|
-
const projectInfo = await eda.dmt_Project.getCurrentProjectInfo();
|
|
816
|
-
|
|
817
|
-
// 2. 复制一个系统库模块到个人库作为演示对象
|
|
818
|
-
const systemLib = await eda.lib_LibrariesList.getSystemLibraryUuid();
|
|
819
|
-
const personalLib = await eda.lib_LibrariesList.getPersonalLibraryUuid();
|
|
820
|
-
const results = await eda.lib_Cbb.search('', systemLib, undefined, 1);
|
|
821
|
-
const source = results[0];
|
|
822
|
-
const cbbUuid = await eda.lib_Cbb.copy(source.uuid, systemLib, personalLib, [], `嘉立创示例_打开符号_${Date.now()}`);
|
|
823
|
-
|
|
824
|
-
// 3. 先打开模块工程(openSymbolInEditor 的前置条件)
|
|
825
|
-
await eda.lib_Cbb.openProjectInEditor(cbbUuid, personalLib);
|
|
826
|
-
await new Promise(r => setTimeout(r, 1000));
|
|
827
|
-
|
|
828
|
-
// 4. 在编辑器打开模块符号,返回标签页 ID
|
|
829
|
-
const tabId = await eda.lib_Cbb.openSymbolInEditor(cbbUuid, personalLib);
|
|
830
|
-
|
|
831
|
-
// 5. 恢复原来打开的工程
|
|
832
|
-
await eda.dmt_Project.openProject(projectInfo.uuid);
|
|
833
|
-
|
|
834
|
-
console.log('source:', source.name, source.uuid);
|
|
835
|
-
console.log('tabId:', tabId);
|
|
836
|
-
```
|
|
837
|
-
|
|
838
|
-
### search
|
|
839
|
-
|
|
840
|
-
# LIB\_Cbb.search() method
|
|
841
|
-
|
|
842
|
-
> This API is provided as a beta preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
|
|
843
|
-
|
|
844
|
-
Search reuse block
|
|
845
|
-
|
|
846
|
-
## Signature
|
|
847
|
-
|
|
848
|
-
```typescript
|
|
849
|
-
function search(
|
|
850
|
-
key: string,
|
|
851
|
-
libraryUuid?: string,
|
|
852
|
-
classification?: ILIB_ClassificationIndex | Array<string>,
|
|
853
|
-
itemsOfPage?: number,
|
|
854
|
-
page?: number,
|
|
855
|
-
): Promise<Array<ILIB_CbbSearchItem>>;
|
|
856
|
-
```
|
|
857
|
-
|
|
858
|
-
## Parameters
|
|
859
|
-
|
|
860
|
-
<table><thead><tr><th>
|
|
861
|
-
|
|
862
|
-
Parameter
|
|
863
|
-
|
|
864
|
-
</th><th>
|
|
865
|
-
|
|
866
|
-
Type
|
|
867
|
-
|
|
868
|
-
</th><th>
|
|
869
|
-
|
|
870
|
-
Description
|
|
871
|
-
|
|
872
|
-
</th></tr></thead>
|
|
873
|
-
<tbody><tr><td>
|
|
874
|
-
|
|
875
|
-
key
|
|
876
|
-
|
|
877
|
-
</td><td>
|
|
878
|
-
|
|
879
|
-
string
|
|
880
|
-
|
|
881
|
-
</td><td>
|
|
882
|
-
|
|
883
|
-
Search keyword
|
|
884
|
-
|
|
885
|
-
</td></tr>
|
|
886
|
-
<tr><td>
|
|
887
|
-
|
|
888
|
-
libraryUuid
|
|
889
|
-
|
|
890
|
-
</td><td>
|
|
891
|
-
|
|
892
|
-
string
|
|
893
|
-
|
|
894
|
-
</td><td>
|
|
895
|
-
|
|
896
|
-
_(Optional)_ Library UUID, default is system library, you can use [LIB\_LibrariesList](./LIB_LibrariesList.md) APIs in
|
|
897
|
-
|
|
898
|
-
</td></tr>
|
|
899
|
-
<tr><td>
|
|
900
|
-
|
|
901
|
-
classification
|
|
902
|
-
|
|
903
|
-
</td><td>
|
|
904
|
-
|
|
905
|
-
[ILIB\_ClassificationIndex](../interfaces/ILIB_ClassificationIndex.md) \| Array<string>
|
|
906
|
-
|
|
907
|
-
</td><td>
|
|
908
|
-
|
|
909
|
-
_(Optional)_ Classification, defaults to all
|
|
910
|
-
|
|
911
|
-
</td></tr>
|
|
912
|
-
<tr><td>
|
|
913
|
-
|
|
914
|
-
itemsOfPage
|
|
915
|
-
|
|
916
|
-
</td><td>
|
|
917
|
-
|
|
918
|
-
number
|
|
919
|
-
|
|
920
|
-
</td><td>
|
|
921
|
-
|
|
922
|
-
_(Optional)_ Number of search results per page
|
|
923
|
-
|
|
924
|
-
</td></tr>
|
|
925
|
-
<tr><td>
|
|
926
|
-
|
|
927
|
-
page
|
|
928
|
-
|
|
929
|
-
</td><td>
|
|
930
|
-
|
|
931
|
-
number
|
|
932
|
-
|
|
933
|
-
</td><td>
|
|
934
|
-
|
|
935
|
-
_(Optional)_ Page count
|
|
936
|
-
|
|
937
|
-
</td></tr>
|
|
938
|
-
</tbody></table>
|
|
939
|
-
|
|
940
|
-
## Returns
|
|
941
|
-
|
|
942
|
-
Promise<Array<[ILIB\_CbbSearchItem](../interfaces/ILIB_CbbSearchItem.md)<!-- -->>>
|
|
943
|
-
|
|
944
|
-
List of searched reuse block properties
|
|
945
|
-
|
|
946
|
-
## Example
|
|
947
|
-
|
|
948
|
-
```javascript
|
|
949
|
-
// 1. 空关键字列出系统库全部复用模块,每页 5 条
|
|
950
|
-
const results = await eda.lib_Cbb.search('', undefined, undefined, 5);
|
|
951
|
-
|
|
952
|
-
// 2. 输出搜索结果
|
|
953
|
-
console.log('count:', results.length);
|
|
954
|
-
results.forEach((item, i) => {
|
|
955
|
-
console.log(`[${i}] name:`, item.name, 'uuid:', item.uuid);
|
|
956
|
-
});
|
|
957
|
-
```
|
|
1
|
+
# LIB\_Cbb class
|
|
2
|
+
|
|
3
|
+
Comprehensive library / reuse block class
|
|
4
|
+
|
|
5
|
+
## Signature
|
|
6
|
+
|
|
7
|
+
```typescript
|
|
8
|
+
class LIB_Cbb
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
## Methods
|
|
12
|
+
|
|
13
|
+
<table><thead><tr><th>
|
|
14
|
+
|
|
15
|
+
Method
|
|
16
|
+
|
|
17
|
+
</th><th>
|
|
18
|
+
|
|
19
|
+
Modifiers
|
|
20
|
+
|
|
21
|
+
</th><th>
|
|
22
|
+
|
|
23
|
+
Description
|
|
24
|
+
|
|
25
|
+
</th></tr></thead>
|
|
26
|
+
<tbody><tr><td>
|
|
27
|
+
|
|
28
|
+
[copy(cbbUuid, libraryUuid, targetLibraryUuid, targetClassification, newCbbName)](./LIB_Cbb.md)
|
|
29
|
+
|
|
30
|
+
</td><td>
|
|
31
|
+
|
|
32
|
+
</td><td>
|
|
33
|
+
|
|
34
|
+
**_(BETA)_** Copy Reuse block
|
|
35
|
+
|
|
36
|
+
</td></tr>
|
|
37
|
+
<tr><td>
|
|
38
|
+
|
|
39
|
+
[create(libraryUuid, cbbName, classification, description)](./LIB_Cbb.md)
|
|
40
|
+
|
|
41
|
+
</td><td>
|
|
42
|
+
|
|
43
|
+
</td><td>
|
|
44
|
+
|
|
45
|
+
**_(BETA)_** Create Reuse block
|
|
46
|
+
|
|
47
|
+
</td></tr>
|
|
48
|
+
<tr><td>
|
|
49
|
+
|
|
50
|
+
[delete(cbbUuid, libraryUuid)](./LIB_Cbb.md)
|
|
51
|
+
|
|
52
|
+
</td><td>
|
|
53
|
+
|
|
54
|
+
</td><td>
|
|
55
|
+
|
|
56
|
+
**_(BETA)_** Delete Reuse block
|
|
57
|
+
|
|
58
|
+
</td></tr>
|
|
59
|
+
<tr><td>
|
|
60
|
+
|
|
61
|
+
[get(cbbUuid, libraryUuid)](./LIB_Cbb.md)
|
|
62
|
+
|
|
63
|
+
</td><td>
|
|
64
|
+
|
|
65
|
+
</td><td>
|
|
66
|
+
|
|
67
|
+
**_(BETA)_** Get all properties of the reuse block
|
|
68
|
+
|
|
69
|
+
</td></tr>
|
|
70
|
+
<tr><td>
|
|
71
|
+
|
|
72
|
+
[modify(cbbUuid, libraryUuid, cbbName, classification, description)](./LIB_Cbb.md)
|
|
73
|
+
|
|
74
|
+
</td><td>
|
|
75
|
+
|
|
76
|
+
</td><td>
|
|
77
|
+
|
|
78
|
+
**_(BETA)_** Modify Reuse block
|
|
79
|
+
|
|
80
|
+
</td></tr>
|
|
81
|
+
<tr><td>
|
|
82
|
+
|
|
83
|
+
[openProjectInEditor(cbbUuid, libraryUuid)](./LIB_Cbb.md)
|
|
84
|
+
|
|
85
|
+
</td><td>
|
|
86
|
+
|
|
87
|
+
</td><td>
|
|
88
|
+
|
|
89
|
+
**_(BETA)_** Open in the editor reuse block project
|
|
90
|
+
|
|
91
|
+
</td></tr>
|
|
92
|
+
<tr><td>
|
|
93
|
+
|
|
94
|
+
[openSymbolInEditor(cbbUuid, libraryUuid, splitScreenId)](./LIB_Cbb.md)
|
|
95
|
+
|
|
96
|
+
</td><td>
|
|
97
|
+
|
|
98
|
+
</td><td>
|
|
99
|
+
|
|
100
|
+
**_(BETA)_** Open in the editor reuse block symbol
|
|
101
|
+
|
|
102
|
+
</td></tr>
|
|
103
|
+
<tr><td>
|
|
104
|
+
|
|
105
|
+
[search(key, libraryUuid, classification, itemsOfPage, page)](./LIB_Cbb.md)
|
|
106
|
+
|
|
107
|
+
</td><td>
|
|
108
|
+
|
|
109
|
+
</td><td>
|
|
110
|
+
|
|
111
|
+
**_(BETA)_** Search reuse block
|
|
112
|
+
|
|
113
|
+
</td></tr>
|
|
114
|
+
</tbody></table>
|
|
115
|
+
|
|
116
|
+
---
|
|
117
|
+
|
|
118
|
+
## 方法详情
|
|
119
|
+
|
|
120
|
+
### copy
|
|
121
|
+
|
|
122
|
+
# LIB\_Cbb.copy() method
|
|
123
|
+
|
|
124
|
+
> This API is provided as a beta preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
|
|
125
|
+
|
|
126
|
+
Copy Reuse block
|
|
127
|
+
|
|
128
|
+
## Signature
|
|
129
|
+
|
|
130
|
+
```typescript
|
|
131
|
+
function copy(
|
|
132
|
+
cbbUuid: string,
|
|
133
|
+
libraryUuid: string,
|
|
134
|
+
targetLibraryUuid: string,
|
|
135
|
+
targetClassification?: ILIB_ClassificationIndex | Array<string>,
|
|
136
|
+
newCbbName?: string,
|
|
137
|
+
): Promise<string | undefined>;
|
|
138
|
+
```
|
|
139
|
+
|
|
140
|
+
## Parameters
|
|
141
|
+
|
|
142
|
+
<table><thead><tr><th>
|
|
143
|
+
|
|
144
|
+
Parameter
|
|
145
|
+
|
|
146
|
+
</th><th>
|
|
147
|
+
|
|
148
|
+
Type
|
|
149
|
+
|
|
150
|
+
</th><th>
|
|
151
|
+
|
|
152
|
+
Description
|
|
153
|
+
|
|
154
|
+
</th></tr></thead>
|
|
155
|
+
<tbody><tr><td>
|
|
156
|
+
|
|
157
|
+
cbbUuid
|
|
158
|
+
|
|
159
|
+
</td><td>
|
|
160
|
+
|
|
161
|
+
string
|
|
162
|
+
|
|
163
|
+
</td><td>
|
|
164
|
+
|
|
165
|
+
Reuse block UUID
|
|
166
|
+
|
|
167
|
+
</td></tr>
|
|
168
|
+
<tr><td>
|
|
169
|
+
|
|
170
|
+
libraryUuid
|
|
171
|
+
|
|
172
|
+
</td><td>
|
|
173
|
+
|
|
174
|
+
string
|
|
175
|
+
|
|
176
|
+
</td><td>
|
|
177
|
+
|
|
178
|
+
Library UUID, you can use [LIB\_LibrariesList](./LIB_LibrariesList.md) APIs in
|
|
179
|
+
|
|
180
|
+
</td></tr>
|
|
181
|
+
<tr><td>
|
|
182
|
+
|
|
183
|
+
targetLibraryUuid
|
|
184
|
+
|
|
185
|
+
</td><td>
|
|
186
|
+
|
|
187
|
+
string
|
|
188
|
+
|
|
189
|
+
</td><td>
|
|
190
|
+
|
|
191
|
+
Target library UUID
|
|
192
|
+
|
|
193
|
+
</td></tr>
|
|
194
|
+
<tr><td>
|
|
195
|
+
|
|
196
|
+
targetClassification
|
|
197
|
+
|
|
198
|
+
</td><td>
|
|
199
|
+
|
|
200
|
+
[ILIB\_ClassificationIndex](../interfaces/ILIB_ClassificationIndex.md) \| Array<string>
|
|
201
|
+
|
|
202
|
+
</td><td>
|
|
203
|
+
|
|
204
|
+
_(Optional)_ Classification in the target library
|
|
205
|
+
|
|
206
|
+
</td></tr>
|
|
207
|
+
<tr><td>
|
|
208
|
+
|
|
209
|
+
newCbbName
|
|
210
|
+
|
|
211
|
+
</td><td>
|
|
212
|
+
|
|
213
|
+
string
|
|
214
|
+
|
|
215
|
+
</td><td>
|
|
216
|
+
|
|
217
|
+
_(Optional)_ New reuse block name. If a reuse block with the same name exists in the target library, the copy will fail
|
|
218
|
+
|
|
219
|
+
</td></tr>
|
|
220
|
+
</tbody></table>
|
|
221
|
+
|
|
222
|
+
## Returns
|
|
223
|
+
|
|
224
|
+
Promise<string \| undefined>
|
|
225
|
+
|
|
226
|
+
UUID of the new reuse block in the target library
|
|
227
|
+
|
|
228
|
+
## Example
|
|
229
|
+
|
|
230
|
+
```javascript
|
|
231
|
+
// 1. 获取系统库与个人库 UUID
|
|
232
|
+
const systemLib = await eda.lib_LibrariesList.getSystemLibraryUuid();
|
|
233
|
+
const personalLib = await eda.lib_LibrariesList.getPersonalLibraryUuid();
|
|
234
|
+
|
|
235
|
+
// 2. 从系统库找一个复用模块作为复制来源
|
|
236
|
+
const results = await eda.lib_Cbb.search('', systemLib, undefined, 1);
|
|
237
|
+
const source = results[0];
|
|
238
|
+
|
|
239
|
+
// 3. 复制到个人库,指定新名称避免同名冲突(分类传 [] = 不分类)
|
|
240
|
+
const newName = `嘉立创示例_复制_${Date.now()}`;
|
|
241
|
+
const copiedUuid = await eda.lib_Cbb.copy(source.uuid, systemLib, personalLib, [], newName);
|
|
242
|
+
|
|
243
|
+
// 创建类保留现场(复制品留在个人库中供观察)
|
|
244
|
+
|
|
245
|
+
console.log('source:', source.name, source.uuid);
|
|
246
|
+
console.log('copiedUuid:', copiedUuid);
|
|
247
|
+
console.log('newName:', newName);
|
|
248
|
+
```
|
|
249
|
+
|
|
250
|
+
### create
|
|
251
|
+
|
|
252
|
+
# LIB\_Cbb.create() method
|
|
253
|
+
|
|
254
|
+
> This API is provided as a beta preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
|
|
255
|
+
|
|
256
|
+
Create Reuse block
|
|
257
|
+
|
|
258
|
+
## Signature
|
|
259
|
+
|
|
260
|
+
```typescript
|
|
261
|
+
function create(
|
|
262
|
+
libraryUuid: string,
|
|
263
|
+
cbbName: string,
|
|
264
|
+
classification?: ILIB_ClassificationIndex | Array<string>,
|
|
265
|
+
description?: string,
|
|
266
|
+
): Promise<string | undefined>;
|
|
267
|
+
```
|
|
268
|
+
|
|
269
|
+
## Parameters
|
|
270
|
+
|
|
271
|
+
<table><thead><tr><th>
|
|
272
|
+
|
|
273
|
+
Parameter
|
|
274
|
+
|
|
275
|
+
</th><th>
|
|
276
|
+
|
|
277
|
+
Type
|
|
278
|
+
|
|
279
|
+
</th><th>
|
|
280
|
+
|
|
281
|
+
Description
|
|
282
|
+
|
|
283
|
+
</th></tr></thead>
|
|
284
|
+
<tbody><tr><td>
|
|
285
|
+
|
|
286
|
+
libraryUuid
|
|
287
|
+
|
|
288
|
+
</td><td>
|
|
289
|
+
|
|
290
|
+
string
|
|
291
|
+
|
|
292
|
+
</td><td>
|
|
293
|
+
|
|
294
|
+
Library UUID, you can use [LIB\_LibrariesList](./LIB_LibrariesList.md) APIs in
|
|
295
|
+
|
|
296
|
+
</td></tr>
|
|
297
|
+
<tr><td>
|
|
298
|
+
|
|
299
|
+
cbbName
|
|
300
|
+
|
|
301
|
+
</td><td>
|
|
302
|
+
|
|
303
|
+
string
|
|
304
|
+
|
|
305
|
+
</td><td>
|
|
306
|
+
|
|
307
|
+
Reuse block name
|
|
308
|
+
|
|
309
|
+
</td></tr>
|
|
310
|
+
<tr><td>
|
|
311
|
+
|
|
312
|
+
classification
|
|
313
|
+
|
|
314
|
+
</td><td>
|
|
315
|
+
|
|
316
|
+
[ILIB\_ClassificationIndex](../interfaces/ILIB_ClassificationIndex.md) \| Array<string>
|
|
317
|
+
|
|
318
|
+
</td><td>
|
|
319
|
+
|
|
320
|
+
_(Optional)_ Classification
|
|
321
|
+
|
|
322
|
+
</td></tr>
|
|
323
|
+
<tr><td>
|
|
324
|
+
|
|
325
|
+
description
|
|
326
|
+
|
|
327
|
+
</td><td>
|
|
328
|
+
|
|
329
|
+
string
|
|
330
|
+
|
|
331
|
+
</td><td>
|
|
332
|
+
|
|
333
|
+
_(Optional)_ Description
|
|
334
|
+
|
|
335
|
+
</td></tr>
|
|
336
|
+
</tbody></table>
|
|
337
|
+
|
|
338
|
+
## Returns
|
|
339
|
+
|
|
340
|
+
Promise<string \| undefined>
|
|
341
|
+
|
|
342
|
+
Reuse block UUID
|
|
343
|
+
|
|
344
|
+
## Example
|
|
345
|
+
|
|
346
|
+
```javascript
|
|
347
|
+
// 1. 获取个人库 UUID
|
|
348
|
+
const libraryUuid = await eda.lib_LibrariesList.getPersonalLibraryUuid();
|
|
349
|
+
|
|
350
|
+
// 2. 在个人库创建复用模块(分类传空数组 = 不分类)
|
|
351
|
+
const cbbName = `嘉立创示例_新建模块_${Date.now()}`;
|
|
352
|
+
const cbbUuid = await eda.lib_Cbb.create(libraryUuid, cbbName, [], '示例描述');
|
|
353
|
+
|
|
354
|
+
// 创建类保留现场
|
|
355
|
+
|
|
356
|
+
console.log('libraryUuid:', libraryUuid);
|
|
357
|
+
console.log('cbbName:', cbbName);
|
|
358
|
+
console.log('cbbUuid:', cbbUuid);
|
|
359
|
+
```
|
|
360
|
+
|
|
361
|
+
### delete
|
|
362
|
+
|
|
363
|
+
# LIB\_Cbb.delete() method
|
|
364
|
+
|
|
365
|
+
> This API is provided as a beta preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
|
|
366
|
+
|
|
367
|
+
Delete Reuse block
|
|
368
|
+
|
|
369
|
+
## Signature
|
|
370
|
+
|
|
371
|
+
```typescript
|
|
372
|
+
function delete(cbbUuid: string, libraryUuid: string): Promise<boolean | undefined>;
|
|
373
|
+
```
|
|
374
|
+
|
|
375
|
+
## Parameters
|
|
376
|
+
|
|
377
|
+
<table><thead><tr><th>
|
|
378
|
+
|
|
379
|
+
Parameter
|
|
380
|
+
|
|
381
|
+
</th><th>
|
|
382
|
+
|
|
383
|
+
Type
|
|
384
|
+
|
|
385
|
+
</th><th>
|
|
386
|
+
|
|
387
|
+
Description
|
|
388
|
+
|
|
389
|
+
</th></tr></thead>
|
|
390
|
+
<tbody><tr><td>
|
|
391
|
+
|
|
392
|
+
cbbUuid
|
|
393
|
+
|
|
394
|
+
</td><td>
|
|
395
|
+
|
|
396
|
+
string
|
|
397
|
+
|
|
398
|
+
</td><td>
|
|
399
|
+
|
|
400
|
+
Reuse block UUID
|
|
401
|
+
|
|
402
|
+
</td></tr>
|
|
403
|
+
<tr><td>
|
|
404
|
+
|
|
405
|
+
libraryUuid
|
|
406
|
+
|
|
407
|
+
</td><td>
|
|
408
|
+
|
|
409
|
+
string
|
|
410
|
+
|
|
411
|
+
</td><td>
|
|
412
|
+
|
|
413
|
+
Library UUID, you can use [LIB\_LibrariesList](./LIB_LibrariesList.md) APIs in
|
|
414
|
+
|
|
415
|
+
</td></tr>
|
|
416
|
+
</tbody></table>
|
|
417
|
+
|
|
418
|
+
## Returns
|
|
419
|
+
|
|
420
|
+
Promise<boolean \| undefined>
|
|
421
|
+
|
|
422
|
+
Whether the operation is successful
|
|
423
|
+
|
|
424
|
+
## Example
|
|
425
|
+
|
|
426
|
+
```javascript
|
|
427
|
+
// 1. 获取系统库与个人库 UUID
|
|
428
|
+
const systemLib = await eda.lib_LibrariesList.getSystemLibraryUuid();
|
|
429
|
+
const personalLib = await eda.lib_LibrariesList.getPersonalLibraryUuid();
|
|
430
|
+
|
|
431
|
+
// 2. 复制一个系统库模块到个人库作为删除对象
|
|
432
|
+
const results = await eda.lib_Cbb.search('', systemLib, undefined, 1);
|
|
433
|
+
const source = results[0];
|
|
434
|
+
const cbbUuid = await eda.lib_Cbb.copy(source.uuid, systemLib, personalLib, [], `嘉立创示例_删除_${Date.now()}`);
|
|
435
|
+
|
|
436
|
+
// 3. 删除复制品
|
|
437
|
+
const deleted = await eda.lib_Cbb.delete(cbbUuid, personalLib);
|
|
438
|
+
|
|
439
|
+
console.log('cbbUuid:', cbbUuid);
|
|
440
|
+
console.log('deleted:', deleted);
|
|
441
|
+
```
|
|
442
|
+
|
|
443
|
+
### get
|
|
444
|
+
|
|
445
|
+
# LIB\_Cbb.get() method
|
|
446
|
+
|
|
447
|
+
> This API is provided as a beta preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
|
|
448
|
+
|
|
449
|
+
Get all properties of the reuse block
|
|
450
|
+
|
|
451
|
+
## Signature
|
|
452
|
+
|
|
453
|
+
```typescript
|
|
454
|
+
function get(cbbUuid: string, libraryUuid?: string): Promise<ILIB_CbbItem | undefined>;
|
|
455
|
+
```
|
|
456
|
+
|
|
457
|
+
## Parameters
|
|
458
|
+
|
|
459
|
+
<table><thead><tr><th>
|
|
460
|
+
|
|
461
|
+
Parameter
|
|
462
|
+
|
|
463
|
+
</th><th>
|
|
464
|
+
|
|
465
|
+
Type
|
|
466
|
+
|
|
467
|
+
</th><th>
|
|
468
|
+
|
|
469
|
+
Description
|
|
470
|
+
|
|
471
|
+
</th></tr></thead>
|
|
472
|
+
<tbody><tr><td>
|
|
473
|
+
|
|
474
|
+
cbbUuid
|
|
475
|
+
|
|
476
|
+
</td><td>
|
|
477
|
+
|
|
478
|
+
string
|
|
479
|
+
|
|
480
|
+
</td><td>
|
|
481
|
+
|
|
482
|
+
Reuse block UUID
|
|
483
|
+
|
|
484
|
+
</td></tr>
|
|
485
|
+
<tr><td>
|
|
486
|
+
|
|
487
|
+
libraryUuid
|
|
488
|
+
|
|
489
|
+
</td><td>
|
|
490
|
+
|
|
491
|
+
string
|
|
492
|
+
|
|
493
|
+
</td><td>
|
|
494
|
+
|
|
495
|
+
_(Optional)_ Library UUID, default is system library, you can use [LIB\_LibrariesList](./LIB_LibrariesList.md) APIs in
|
|
496
|
+
|
|
497
|
+
</td></tr>
|
|
498
|
+
</tbody></table>
|
|
499
|
+
|
|
500
|
+
## Returns
|
|
501
|
+
|
|
502
|
+
Promise<[ILIB\_CbbItem](../interfaces/ILIB_CbbItem.md) \| undefined>
|
|
503
|
+
|
|
504
|
+
Reuse block property
|
|
505
|
+
|
|
506
|
+
### modify
|
|
507
|
+
|
|
508
|
+
# LIB\_Cbb.modify() method
|
|
509
|
+
|
|
510
|
+
> This API is provided as a beta preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
|
|
511
|
+
|
|
512
|
+
Modify Reuse block
|
|
513
|
+
|
|
514
|
+
## Signature
|
|
515
|
+
|
|
516
|
+
```typescript
|
|
517
|
+
function modify(
|
|
518
|
+
cbbUuid: string,
|
|
519
|
+
libraryUuid: string,
|
|
520
|
+
cbbName?: string,
|
|
521
|
+
classification?: ILIB_ClassificationIndex | Array<string> | null,
|
|
522
|
+
description?: string | null,
|
|
523
|
+
): Promise<boolean>;
|
|
524
|
+
```
|
|
525
|
+
|
|
526
|
+
## Parameters
|
|
527
|
+
|
|
528
|
+
<table><thead><tr><th>
|
|
529
|
+
|
|
530
|
+
Parameter
|
|
531
|
+
|
|
532
|
+
</th><th>
|
|
533
|
+
|
|
534
|
+
Type
|
|
535
|
+
|
|
536
|
+
</th><th>
|
|
537
|
+
|
|
538
|
+
Description
|
|
539
|
+
|
|
540
|
+
</th></tr></thead>
|
|
541
|
+
<tbody><tr><td>
|
|
542
|
+
|
|
543
|
+
cbbUuid
|
|
544
|
+
|
|
545
|
+
</td><td>
|
|
546
|
+
|
|
547
|
+
string
|
|
548
|
+
|
|
549
|
+
</td><td>
|
|
550
|
+
|
|
551
|
+
Reuse block UUID
|
|
552
|
+
|
|
553
|
+
</td></tr>
|
|
554
|
+
<tr><td>
|
|
555
|
+
|
|
556
|
+
libraryUuid
|
|
557
|
+
|
|
558
|
+
</td><td>
|
|
559
|
+
|
|
560
|
+
string
|
|
561
|
+
|
|
562
|
+
</td><td>
|
|
563
|
+
|
|
564
|
+
Library UUID, you can use [LIB\_LibrariesList](./LIB_LibrariesList.md) APIs in
|
|
565
|
+
|
|
566
|
+
</td></tr>
|
|
567
|
+
<tr><td>
|
|
568
|
+
|
|
569
|
+
cbbName
|
|
570
|
+
|
|
571
|
+
</td><td>
|
|
572
|
+
|
|
573
|
+
string
|
|
574
|
+
|
|
575
|
+
</td><td>
|
|
576
|
+
|
|
577
|
+
_(Optional)_ Reuse block name
|
|
578
|
+
|
|
579
|
+
</td></tr>
|
|
580
|
+
<tr><td>
|
|
581
|
+
|
|
582
|
+
classification
|
|
583
|
+
|
|
584
|
+
</td><td>
|
|
585
|
+
|
|
586
|
+
[ILIB\_ClassificationIndex](../interfaces/ILIB_ClassificationIndex.md) \| Array<string> \| null
|
|
587
|
+
|
|
588
|
+
</td><td>
|
|
589
|
+
|
|
590
|
+
_(Optional)_ Classification
|
|
591
|
+
|
|
592
|
+
</td></tr>
|
|
593
|
+
<tr><td>
|
|
594
|
+
|
|
595
|
+
description
|
|
596
|
+
|
|
597
|
+
</td><td>
|
|
598
|
+
|
|
599
|
+
string \| null
|
|
600
|
+
|
|
601
|
+
</td><td>
|
|
602
|
+
|
|
603
|
+
_(Optional)_ Description
|
|
604
|
+
|
|
605
|
+
</td></tr>
|
|
606
|
+
</tbody></table>
|
|
607
|
+
|
|
608
|
+
## Returns
|
|
609
|
+
|
|
610
|
+
Promise<boolean>
|
|
611
|
+
|
|
612
|
+
Whether the operation is successful
|
|
613
|
+
|
|
614
|
+
## Remarks
|
|
615
|
+
|
|
616
|
+
If you want to clear certain properties, set their values to `null`
|
|
617
|
+
|
|
618
|
+
## Example
|
|
619
|
+
|
|
620
|
+
```javascript
|
|
621
|
+
// 1. 获取系统库与个人库 UUID
|
|
622
|
+
const systemLib = await eda.lib_LibrariesList.getSystemLibraryUuid();
|
|
623
|
+
const personalLib = await eda.lib_LibrariesList.getPersonalLibraryUuid();
|
|
624
|
+
|
|
625
|
+
// 2. 复制一个系统库模块到个人库作为修改对象
|
|
626
|
+
const results = await eda.lib_Cbb.search('', systemLib, undefined, 1);
|
|
627
|
+
const source = results[0];
|
|
628
|
+
const cbbUuid = await eda.lib_Cbb.copy(source.uuid, systemLib, personalLib, [], `嘉立创示例_修改_${Date.now()}`);
|
|
629
|
+
|
|
630
|
+
// 3. 修改名称和描述(分类保持不变传 [])
|
|
631
|
+
const newName = `嘉立创示例_重命名_${Date.now()}`;
|
|
632
|
+
const modified = await eda.lib_Cbb.modify(cbbUuid, personalLib, newName, [], '修改后的描述');
|
|
633
|
+
|
|
634
|
+
// 修改类保留现场
|
|
635
|
+
|
|
636
|
+
console.log('cbbUuid:', cbbUuid);
|
|
637
|
+
console.log('modified:', modified);
|
|
638
|
+
console.log('newName:', newName);
|
|
639
|
+
```
|
|
640
|
+
|
|
641
|
+
### openprojectineditor
|
|
642
|
+
|
|
643
|
+
# LIB\_Cbb.openProjectInEditor() method
|
|
644
|
+
|
|
645
|
+
> This API is provided as a beta preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
|
|
646
|
+
|
|
647
|
+
Open in the editor reuse block project
|
|
648
|
+
|
|
649
|
+
## Signature
|
|
650
|
+
|
|
651
|
+
```typescript
|
|
652
|
+
function openProjectInEditor(cbbUuid: string, libraryUuid: string): Promise<boolean>;
|
|
653
|
+
```
|
|
654
|
+
|
|
655
|
+
## Parameters
|
|
656
|
+
|
|
657
|
+
<table><thead><tr><th>
|
|
658
|
+
|
|
659
|
+
Parameter
|
|
660
|
+
|
|
661
|
+
</th><th>
|
|
662
|
+
|
|
663
|
+
Type
|
|
664
|
+
|
|
665
|
+
</th><th>
|
|
666
|
+
|
|
667
|
+
Description
|
|
668
|
+
|
|
669
|
+
</th></tr></thead>
|
|
670
|
+
<tbody><tr><td>
|
|
671
|
+
|
|
672
|
+
cbbUuid
|
|
673
|
+
|
|
674
|
+
</td><td>
|
|
675
|
+
|
|
676
|
+
string
|
|
677
|
+
|
|
678
|
+
</td><td>
|
|
679
|
+
|
|
680
|
+
Reuse block UUID
|
|
681
|
+
|
|
682
|
+
</td></tr>
|
|
683
|
+
<tr><td>
|
|
684
|
+
|
|
685
|
+
libraryUuid
|
|
686
|
+
|
|
687
|
+
</td><td>
|
|
688
|
+
|
|
689
|
+
string
|
|
690
|
+
|
|
691
|
+
</td><td>
|
|
692
|
+
|
|
693
|
+
Library UUID, you can use [LIB\_LibrariesList](./LIB_LibrariesList.md) APIs in
|
|
694
|
+
|
|
695
|
+
</td></tr>
|
|
696
|
+
</tbody></table>
|
|
697
|
+
|
|
698
|
+
## Returns
|
|
699
|
+
|
|
700
|
+
Promise<boolean>
|
|
701
|
+
|
|
702
|
+
## Remarks
|
|
703
|
+
|
|
704
|
+
This operation will open the module project in the EDA front end. If another project was previously opened with unsaved changes, executing this operation will directly lose all unsaved data
|
|
705
|
+
|
|
706
|
+
## Example
|
|
707
|
+
|
|
708
|
+
```javascript
|
|
709
|
+
// 1. 记录当前工程,便于演示结束后恢复
|
|
710
|
+
const projectInfo = await eda.dmt_Project.getCurrentProjectInfo();
|
|
711
|
+
|
|
712
|
+
// 2. 复制一个系统库模块到个人库作为打开对象
|
|
713
|
+
const systemLib = await eda.lib_LibrariesList.getSystemLibraryUuid();
|
|
714
|
+
const personalLib = await eda.lib_LibrariesList.getPersonalLibraryUuid();
|
|
715
|
+
const results = await eda.lib_Cbb.search('', systemLib, undefined, 1);
|
|
716
|
+
const source = results[0];
|
|
717
|
+
const cbbUuid = await eda.lib_Cbb.copy(source.uuid, systemLib, personalLib, [], `嘉立创示例_打开工程_${Date.now()}`);
|
|
718
|
+
|
|
719
|
+
// 3. 在编辑器打开模块工程
|
|
720
|
+
const opened = await eda.lib_Cbb.openProjectInEditor(cbbUuid, personalLib);
|
|
721
|
+
|
|
722
|
+
// 4. 恢复原来打开的工程
|
|
723
|
+
await new Promise(r => setTimeout(r, 1000));
|
|
724
|
+
await eda.dmt_Project.openProject(projectInfo.uuid);
|
|
725
|
+
|
|
726
|
+
console.log('source:', source.name, source.uuid);
|
|
727
|
+
console.log('opened:', opened);
|
|
728
|
+
console.log('restored:', projectInfo.uuid);
|
|
729
|
+
```
|
|
730
|
+
|
|
731
|
+
### opensymbolineditor
|
|
732
|
+
|
|
733
|
+
# LIB\_Cbb.openSymbolInEditor() method
|
|
734
|
+
|
|
735
|
+
> This API is provided as a beta preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
|
|
736
|
+
|
|
737
|
+
Open in the editor reuse block symbol
|
|
738
|
+
|
|
739
|
+
## Signature
|
|
740
|
+
|
|
741
|
+
```typescript
|
|
742
|
+
function openSymbolInEditor(
|
|
743
|
+
cbbUuid: string,
|
|
744
|
+
libraryUuid: string,
|
|
745
|
+
splitScreenId?: string,
|
|
746
|
+
): Promise<string | undefined>;
|
|
747
|
+
```
|
|
748
|
+
|
|
749
|
+
## Parameters
|
|
750
|
+
|
|
751
|
+
<table><thead><tr><th>
|
|
752
|
+
|
|
753
|
+
Parameter
|
|
754
|
+
|
|
755
|
+
</th><th>
|
|
756
|
+
|
|
757
|
+
Type
|
|
758
|
+
|
|
759
|
+
</th><th>
|
|
760
|
+
|
|
761
|
+
Description
|
|
762
|
+
|
|
763
|
+
</th></tr></thead>
|
|
764
|
+
<tbody><tr><td>
|
|
765
|
+
|
|
766
|
+
cbbUuid
|
|
767
|
+
|
|
768
|
+
</td><td>
|
|
769
|
+
|
|
770
|
+
string
|
|
771
|
+
|
|
772
|
+
</td><td>
|
|
773
|
+
|
|
774
|
+
Reuse block UUID
|
|
775
|
+
|
|
776
|
+
</td></tr>
|
|
777
|
+
<tr><td>
|
|
778
|
+
|
|
779
|
+
libraryUuid
|
|
780
|
+
|
|
781
|
+
</td><td>
|
|
782
|
+
|
|
783
|
+
string
|
|
784
|
+
|
|
785
|
+
</td><td>
|
|
786
|
+
|
|
787
|
+
Library UUID, you can use [LIB\_LibrariesList](./LIB_LibrariesList.md) APIs in
|
|
788
|
+
|
|
789
|
+
</td></tr>
|
|
790
|
+
<tr><td>
|
|
791
|
+
|
|
792
|
+
splitScreenId
|
|
793
|
+
|
|
794
|
+
</td><td>
|
|
795
|
+
|
|
796
|
+
string
|
|
797
|
+
|
|
798
|
+
</td><td>
|
|
799
|
+
|
|
800
|
+
_(Optional)_ Split screen ID. If not filled in, it opens in the split screen with the last input focus by default. It can be obtained using the APIs in [DMT\_EditorControl](./DMT_EditorControl.md)
|
|
801
|
+
|
|
802
|
+
</td></tr>
|
|
803
|
+
</tbody></table>
|
|
804
|
+
|
|
805
|
+
## Returns
|
|
806
|
+
|
|
807
|
+
Promise<string \| undefined>
|
|
808
|
+
|
|
809
|
+
Tab ID, corresponding to [IDMT\_EditorTabItem.tabId](../interfaces/IDMT_EditorTabItem.md)<!-- -->. You can use [DMT\_EditorControl.getSplitScreenIdByTabId()](./DMT_EditorControl.md) to get the split screen ID
|
|
810
|
+
|
|
811
|
+
## Example
|
|
812
|
+
|
|
813
|
+
```javascript
|
|
814
|
+
// 1. 记录当前工程,便于演示结束后恢复
|
|
815
|
+
const projectInfo = await eda.dmt_Project.getCurrentProjectInfo();
|
|
816
|
+
|
|
817
|
+
// 2. 复制一个系统库模块到个人库作为演示对象
|
|
818
|
+
const systemLib = await eda.lib_LibrariesList.getSystemLibraryUuid();
|
|
819
|
+
const personalLib = await eda.lib_LibrariesList.getPersonalLibraryUuid();
|
|
820
|
+
const results = await eda.lib_Cbb.search('', systemLib, undefined, 1);
|
|
821
|
+
const source = results[0];
|
|
822
|
+
const cbbUuid = await eda.lib_Cbb.copy(source.uuid, systemLib, personalLib, [], `嘉立创示例_打开符号_${Date.now()}`);
|
|
823
|
+
|
|
824
|
+
// 3. 先打开模块工程(openSymbolInEditor 的前置条件)
|
|
825
|
+
await eda.lib_Cbb.openProjectInEditor(cbbUuid, personalLib);
|
|
826
|
+
await new Promise(r => setTimeout(r, 1000));
|
|
827
|
+
|
|
828
|
+
// 4. 在编辑器打开模块符号,返回标签页 ID
|
|
829
|
+
const tabId = await eda.lib_Cbb.openSymbolInEditor(cbbUuid, personalLib);
|
|
830
|
+
|
|
831
|
+
// 5. 恢复原来打开的工程
|
|
832
|
+
await eda.dmt_Project.openProject(projectInfo.uuid);
|
|
833
|
+
|
|
834
|
+
console.log('source:', source.name, source.uuid);
|
|
835
|
+
console.log('tabId:', tabId);
|
|
836
|
+
```
|
|
837
|
+
|
|
838
|
+
### search
|
|
839
|
+
|
|
840
|
+
# LIB\_Cbb.search() method
|
|
841
|
+
|
|
842
|
+
> This API is provided as a beta preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
|
|
843
|
+
|
|
844
|
+
Search reuse block
|
|
845
|
+
|
|
846
|
+
## Signature
|
|
847
|
+
|
|
848
|
+
```typescript
|
|
849
|
+
function search(
|
|
850
|
+
key: string,
|
|
851
|
+
libraryUuid?: string,
|
|
852
|
+
classification?: ILIB_ClassificationIndex | Array<string>,
|
|
853
|
+
itemsOfPage?: number,
|
|
854
|
+
page?: number,
|
|
855
|
+
): Promise<Array<ILIB_CbbSearchItem>>;
|
|
856
|
+
```
|
|
857
|
+
|
|
858
|
+
## Parameters
|
|
859
|
+
|
|
860
|
+
<table><thead><tr><th>
|
|
861
|
+
|
|
862
|
+
Parameter
|
|
863
|
+
|
|
864
|
+
</th><th>
|
|
865
|
+
|
|
866
|
+
Type
|
|
867
|
+
|
|
868
|
+
</th><th>
|
|
869
|
+
|
|
870
|
+
Description
|
|
871
|
+
|
|
872
|
+
</th></tr></thead>
|
|
873
|
+
<tbody><tr><td>
|
|
874
|
+
|
|
875
|
+
key
|
|
876
|
+
|
|
877
|
+
</td><td>
|
|
878
|
+
|
|
879
|
+
string
|
|
880
|
+
|
|
881
|
+
</td><td>
|
|
882
|
+
|
|
883
|
+
Search keyword
|
|
884
|
+
|
|
885
|
+
</td></tr>
|
|
886
|
+
<tr><td>
|
|
887
|
+
|
|
888
|
+
libraryUuid
|
|
889
|
+
|
|
890
|
+
</td><td>
|
|
891
|
+
|
|
892
|
+
string
|
|
893
|
+
|
|
894
|
+
</td><td>
|
|
895
|
+
|
|
896
|
+
_(Optional)_ Library UUID, default is system library, you can use [LIB\_LibrariesList](./LIB_LibrariesList.md) APIs in
|
|
897
|
+
|
|
898
|
+
</td></tr>
|
|
899
|
+
<tr><td>
|
|
900
|
+
|
|
901
|
+
classification
|
|
902
|
+
|
|
903
|
+
</td><td>
|
|
904
|
+
|
|
905
|
+
[ILIB\_ClassificationIndex](../interfaces/ILIB_ClassificationIndex.md) \| Array<string>
|
|
906
|
+
|
|
907
|
+
</td><td>
|
|
908
|
+
|
|
909
|
+
_(Optional)_ Classification, defaults to all
|
|
910
|
+
|
|
911
|
+
</td></tr>
|
|
912
|
+
<tr><td>
|
|
913
|
+
|
|
914
|
+
itemsOfPage
|
|
915
|
+
|
|
916
|
+
</td><td>
|
|
917
|
+
|
|
918
|
+
number
|
|
919
|
+
|
|
920
|
+
</td><td>
|
|
921
|
+
|
|
922
|
+
_(Optional)_ Number of search results per page
|
|
923
|
+
|
|
924
|
+
</td></tr>
|
|
925
|
+
<tr><td>
|
|
926
|
+
|
|
927
|
+
page
|
|
928
|
+
|
|
929
|
+
</td><td>
|
|
930
|
+
|
|
931
|
+
number
|
|
932
|
+
|
|
933
|
+
</td><td>
|
|
934
|
+
|
|
935
|
+
_(Optional)_ Page count
|
|
936
|
+
|
|
937
|
+
</td></tr>
|
|
938
|
+
</tbody></table>
|
|
939
|
+
|
|
940
|
+
## Returns
|
|
941
|
+
|
|
942
|
+
Promise<Array<[ILIB\_CbbSearchItem](../interfaces/ILIB_CbbSearchItem.md)<!-- -->>>
|
|
943
|
+
|
|
944
|
+
List of searched reuse block properties
|
|
945
|
+
|
|
946
|
+
## Example
|
|
947
|
+
|
|
948
|
+
```javascript
|
|
949
|
+
// 1. 空关键字列出系统库全部复用模块,每页 5 条
|
|
950
|
+
const results = await eda.lib_Cbb.search('', undefined, undefined, 5);
|
|
951
|
+
|
|
952
|
+
// 2. 输出搜索结果
|
|
953
|
+
console.log('count:', results.length);
|
|
954
|
+
results.forEach((item, i) => {
|
|
955
|
+
console.log(`[${i}] name:`, item.name, 'uuid:', item.uuid);
|
|
956
|
+
});
|
|
957
|
+
```
|