Search this API

y.layout.tree
Interface FromSketchNodePlacer

All Superinterfaces:
NodePlacer
All Known Implementing Classes:
AbstractRotatableNodePlacer, ARNodePlacer, AssistantPlacer, BusPlacer, DefaultNodePlacer, DelegatingNodePlacer, DendrogramPlacer, DoubleLinePlacer, FreePlacer, GridNodePlacer, LayeredNodePlacer, LeftRightPlacer, SimpleNodePlacer

public interface FromSketchNodePlacer
extends NodePlacer

A FromSketchNodePlacer arranges the subtrees while taking the initial locations of the nodes into account.

It provides a Comparator which sorts the outgoing edges of a node according to the initial coordinates of their target nodes. Keeping the original order of nodes, this Comparator allows to incrementally add new nodes to the graph.

 

Field Summary
 
Fields inherited from interface y.layout.tree.NodePlacer
DIRECTION_ANY, DIRECTION_EAST, DIRECTION_NONE, DIRECTION_NORTH, DIRECTION_SOUTH, DIRECTION_WEST
 
Method Summary
 java.util.Comparator createFromSketchComparator()
          Creates an edge comparator which takes the initial coordinates of the nodes into account.
 
Methods inherited from interface y.layout.tree.NodePlacer
createProcessor, determineChildConnectors, placeSubtree
 

Method Detail

createFromSketchComparator

java.util.Comparator createFromSketchComparator()
Creates an edge comparator which takes the initial coordinates of the nodes into account.

This Comparator defines the order of the outgoing edges of a node before the actual placement of the node's subtree is calculated.

Returns:
the Comparator for the edges

© Copyright 2000-2021,
yWorks GmbH.
All rights reserved.