/** Core */ import { Generic } from "cmf.core/src/core"; /** Model */ import * as Model from "./nodeEditorModel"; /** NodeEditor */ import { NodeEditor } from "./nodeEditorBase"; /** * NodeEditor utils */ export declare class NodeEditorUtils extends Generic { /** * Node editor instance */ private _nodeEditor; /** * Constructor * @param nodeEditor */ constructor(nodeEditor: NodeEditor); /** * Compares to points - truncates the values before comparison * @param a First point to compare * @param b Second point to compare */ pointsAreEqual(a: Model.NodeEditorPoint, b: Model.NodeEditorPoint): boolean; /** * Get copy of data for output * @param original */ getCopyOfDataForOutput(original: Model.NodeEditorModel): Model.NodeEditorModel; /** * Clone node safely * @param node */ cloneNode(node: Model.NodeEditorNode): Model.NodeEditorNode; /** * Clone link safely * @param link */ cloneLink(link: Model.NodeEditorLink): Model.NodeEditorLink; /** * Get icon glyph code by icon class * @param iconClass */ getIconGlyphCode(iconClass: string): string; /** * Instantiate NodeEditor custom graph elements */ instantiateNodeEditorCustomGraphElements(): void; /** * Get element of the data model by id * @param id the element id */ getGraphElementById(data: Model.NodeEditorModel, id: string): { type: string; element: Model.NodeEditorNode | Model.NodeEditorLink; }; /** * Get a link by its id * @param id the id */ getLinkById(data: Model.NodeEditorModel, id: string): Model.NodeEditorLink; /** * Get a node by its id * @param id the id */ getNodeById(data: Model.NodeEditorModel, id: string): Model.NodeEditorNode; }