|
Search this API | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object y.layout.AbstractLayoutStage y.layout.grouping.GroupNodeHider
public class GroupNodeHider
A layout stage for hierarchically grouped graphs. Activating this stage removes all group nodes and adjacent edges from the graph before passing it on to its core layouter. After the core layouter has arranged the graph, the hidden elements will be reinserted in the graph again.
Field Summary |
---|
Fields inherited from interface y.layout.Layouter |
---|
EDGE_ID_DPKEY, NODE_ID_DPKEY, SELECTED_EDGES, SELECTED_NODES |
Constructor Summary | |
---|---|
GroupNodeHider()
Creates a new instance of GroupNodeHider |
|
GroupNodeHider(Layouter coreLayouter)
Creates a new instance of GroupNodeHider. |
Method Summary | |
---|---|
boolean |
canLayout(LayoutGraph graph)
Returns true iff the given graph can be laid
out by this algorithm. |
void |
doLayout(LayoutGraph graph)
Main layout routine that assigns new layout information to the given graph. |
GroupBoundsCalculator |
getGroupBoundsCalculator()
Returns the currently installed GroupBoundsCalculator instance |
void |
hideGroupNodes(LayoutGraph graph)
Hides the group nodes and adjacent edges from the graph. |
boolean |
isHidingEmptyGroupNodes()
Returns whether or not group nodes without children will be hidden. |
void |
setGroupBoundsCalculator(GroupBoundsCalculator calc)
Sets the new GroupBoundsCalculator instance. |
void |
setHidingEmptyGroupNodes(boolean hidingEmptyGroupNodes)
Sets whether or not group nodes without children will be hidden. |
void |
unhideGroupNodes(LayoutGraph graph)
Unhides group nodes and adjacent edges from the graph that were previously hidden using method hideGroupNodes(y.layout.LayoutGraph) . |
Methods inherited from class y.layout.AbstractLayoutStage |
---|
canLayoutCore, doLayoutCore, getCoreLayouter, setCoreLayouter |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public GroupNodeHider()
public GroupNodeHider(Layouter coreLayouter)
coreLayouter
- the core layouter used by this layout stage.Method Detail |
---|
public boolean isHidingEmptyGroupNodes()
true
.
true
if all group nodes will be hidden;
false
if only group nodes with children will be hidden.public void setHidingEmptyGroupNodes(boolean hidingEmptyGroupNodes)
true
.
hidingEmptyGroupNodes
- if true
all group nodes will be
hidden; if false
only group nodes with children will be
hidden.public void hideGroupNodes(LayoutGraph graph)
public void unhideGroupNodes(LayoutGraph graph)
hideGroupNodes(y.layout.LayoutGraph)
. Furthermore this method restores all
previously removed grouping related DataProviders on the input graph.
public void setGroupBoundsCalculator(GroupBoundsCalculator calc)
calc
- New GroupBoundsCalculator instance.public GroupBoundsCalculator getGroupBoundsCalculator()
public boolean canLayout(LayoutGraph graph)
Layouter
true
iff the given graph can be laid
out by this algorithm. Calling doLayout
with
the given graph as its argument will only success if
this method returns true
.
public void doLayout(LayoutGraph graph)
Layouter
|
© Copyright 2000-2013, yWorks GmbH. All rights reserved. |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |