Esempio n. 1
0
        private DiagramNodeLayoutVertex CreateLayoutVertex(IDiagramNode diagramNode, Map <ModelNodeId, DiagramNodeLayoutVertex> diagramNodeToLayoutVertexMap)
        {
            if (diagramNodeToLayoutVertexMap.Contains(diagramNode.Id))
            {
                throw new InvalidOperationException($"Diagram node {diagramNode} already added.");
            }

            var diagramNodeLayoutPriority = _layoutPriorityProvider.GetPriority(diagramNode);
            var diagramNodeLayoutVertex   = new DiagramNodeLayoutVertex(diagramNode, diagramNodeLayoutPriority);

            diagramNodeToLayoutVertexMap.Set(diagramNode.Id, diagramNodeLayoutVertex);

            return(diagramNodeLayoutVertex);
        }
Esempio n. 2
0
 public LayoutPath(DiagramNodeLayoutVertex sourceVertex, DiagramNodeLayoutVertex targetVertex,
                   IDiagramConnector diagramConnector)
     : this(new GeneralLayoutEdge(sourceVertex, targetVertex, diagramConnector))
 {
 }