|
Search this API | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface EdgeReverser
This interface handles edges that should be reversed during the hierarchic layout process.
EdgeReverser
contains methods for reversing all (or a given edge) that point to the wrong direction, i.e.
the layer indices of the source nodes are greater than the layer indices of the target nodes. It also provides
methods to restore the edges that have been reversed at the end of the layout algorithm.
Implementations of this interface perform operations after the layering phase of the hierarchic layout algorithm.
HierarchicLayouter
![]() |
![]() |
Method Summary | |
---|---|
void |
normalizeEdges(LayoutGraph graph,
LayoutDataProvider ldp)
Reverses all edges which point to the wrong direction. |
void |
restoreEdgeDirections(LayoutGraph graph,
LayoutDataProvider ldp)
Restores the original direction of edges marked as reversed. |
void |
reverse(LayoutGraph graph,
LayoutDataProvider ldp,
Edge edge)
Reverses a given edge which points to the wrong direction. |
Method Detail |
---|
void normalizeEdges(LayoutGraph graph, LayoutDataProvider ldp)
It is called after the layering phase of the hierarchic layout algorithm
.
An edge is reversed if the layer index of its source node is greater than the layer index of its target node.
graph
- the input graphldp
- the LayoutDataProvider
containing layering information about the nodes and edges of the graphLayoutDataProvider.getNodeData(y.base.Node)
,
NodeData.getLayer()
void reverse(LayoutGraph graph, LayoutDataProvider ldp, Edge edge)
It may be called by the incremental parts of the hierarchic layout algorithm
.
graph
- the input graphldp
- the LayoutDataProvider
containing layering information about the nodes and edges of the graphedge
- the edge to be reversedLayoutDataProvider.getNodeData(y.base.Node)
,
NodeData.getLayer()
void restoreEdgeDirections(LayoutGraph graph, LayoutDataProvider ldp)
It is called at the end of the hierarchic layout algorithm
.
graph
- the input graphldp
- the LayoutDataProvider
containing information about the nodes and edges of the graph
|
© Copyright 2000-2022, yWorks GmbH. All rights reserved. |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |