y.layout.hierarchic
Class TreeDrawer.HierarchicTreePlacer
java.lang.Object
y.layout.tree.AbstractNodePlacer
y.layout.hierarchic.TreeDrawer.HierarchicTreePlacer
- All Implemented Interfaces:
- Cloneable, NodePlacer
- Enclosing class:
- TreeDrawer
public static class TreeDrawer.HierarchicTreePlacer
- extends AbstractNodePlacer
places nodes in their given layers (does not change the y coordinates) for the TREE layout style of a
HierarchicLayouter.
TreeDrawer.HierarchicTreePlacer
public TreeDrawer.HierarchicTreePlacer(double minimalNodeDistance)
- creates a new HierarchicTreePlacer.
- Parameters:
minimalNodeDistance
- the minimal allowed distance between two nodes in the same layer
determineChildConnector
protected byte determineChildConnector(Node child)
- Description copied from class:
AbstractNodePlacer
- This method must be implemented by subclasses. It assigns a connector shape
direction to each child.
- Specified by:
determineChildConnector
in class AbstractNodePlacer
- Parameters:
child
- the child node
- Returns:
- a byte constant as defined in the
NodePlacer
interface
placeSubtree
protected GenericTreeLayouter.SubtreeShape placeSubtree(Node localRoot,
byte parentConnectorDirection)
- Description copied from class:
AbstractNodePlacer
- The main placeSubtree method that must be implemented by subclasses.
- Specified by:
placeSubtree
in class AbstractNodePlacer
- Parameters:
localRoot
- the local root nodeparentConnectorDirection
- the direction of the connector shape
- Returns:
- a SubtreeShape instance that describes the shape of the whole subtree