y.layout.grouping
Class GroupNodeHider

java.lang.Object
  |
  +--y.layout.AbstractLayoutStage
        |
        +--y.layout.grouping.GroupNodeHider
All Implemented Interfaces:
Layouter, LayoutStage

public class GroupNodeHider
extends AbstractLayoutStage

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 eleemnts 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 layed out by this algorithm.
 void doLayout(LayoutGraph graph)
          Assigns a new graph layout to the given layout graph.
 
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

GroupNodeHider

public GroupNodeHider()
Creates a new instance of GroupNodeHider


GroupNodeHider

public GroupNodeHider(Layouter coreLayouter)
Creates a new instance of GroupNodeHider.

Parameters:
coreLayouter - the core layouter used by this layout stage.
Method Detail

canLayout

public boolean canLayout(LayoutGraph graph)
Description copied from interface: Layouter
Returns true iff the given graph can be layed out by this algorithm. Calling doLayout with the given graph as it's argument will only success if this method returns true.


doLayout

public void doLayout(LayoutGraph graph)
Description copied from interface: Layouter
Assigns a new graph layout to the given layout graph.


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

2003