Class GecodeTreeLayout
java.lang.Object
org.jgraph.layout.JGraphLayoutAlgorithm
de.saar.chorus.jgraph.improvedjgraph.layout.ImprovedJGraphLayout
de.saar.chorus.jgraph.improvedjgraph.layout.treelayout.GecodeTreeLayout
A layout algorithm for a solved form of a dominance graph
represented by a
JDomGraph. This tree layout
uses the GECODE tree layout classes.- Author:
- Michaela Regneri
-
Constructor Summary
ConstructorsConstructorDescriptionInitializes a newSolvedFormLayoutwith the givenJDomGraph.GecodeTreeLayout(ImprovedJGraph gr, int offset) Initializes a newSolvedFormLayoutwith the givenJDomGraph. -
Method Summary
Modifier and TypeMethodDescriptionvoidaddRelXtoParent(org.jgraph.graph.DefaultGraphCell node, Integer x) voidaddRelXtoRoot(org.jgraph.graph.DefaultGraphCell node, Integer x) voidaddRelYpos(org.jgraph.graph.DefaultGraphCell node, Integer y) getNodesToShape(org.jgraph.graph.DefaultGraphCell node) intgetNodeWidth(org.jgraph.graph.DefaultGraphCell node) Returns the node width computed by theJDomGraph.getRelXtoParent(org.jgraph.graph.DefaultGraphCell node) voidputNodeToShape(org.jgraph.graph.DefaultGraphCell node, Shape shape) voidStarts the layout algorithm.Methods inherited from class org.jgraph.layout.JGraphLayoutAlgorithm
createDialog, createDialog, createSettings, getHint, getMaximumProgress, getProgress, isAllowedToRun, populateDialog, run, setAllowedToRun, setMaximumProgress, setProgress
-
Constructor Details
-
GecodeTreeLayout
Initializes a newSolvedFormLayoutwith the givenJDomGraph.- Parameters:
gr- the solved form asJDomGraphto layout
-
GecodeTreeLayout
Initializes a newSolvedFormLayoutwith the givenJDomGraph.- Parameters:
gr- the solved form asJDomGraphto layout
-
-
Method Details
-
run
Starts the layout algorithm.- Specified by:
runin classImprovedJGraphLayout
-
getRelXtoParent
- Specified by:
getRelXtoParentin classImprovedJGraphLayout
-
addRelXtoParent
- Specified by:
addRelXtoParentin classImprovedJGraphLayout
-
addRelXtoRoot
- Specified by:
addRelXtoRootin classImprovedJGraphLayout
-
addRelYpos
- Specified by:
addRelYposin classImprovedJGraphLayout
-
getNodeWidth
public int getNodeWidth(org.jgraph.graph.DefaultGraphCell node) Returns the node width computed by theJDomGraph.- Specified by:
getNodeWidthin classImprovedJGraphLayout- Parameters:
node- the node to compute the width for- Returns:
- the width
-
getNodesToShape
- Specified by:
getNodesToShapein classImprovedJGraphLayout
-
putNodeToShape
- Specified by:
putNodeToShapein classImprovedJGraphLayout
-