Search this API

y.layout.organic
Class GroupedShuffleLayouter

java.lang.Object
  extended by y.layout.AbstractLayoutStage
      extended by y.layout.organic.GroupedShuffleLayouter
All Implemented Interfaces:
Layouter, LayoutStage

public class GroupedShuffleLayouter
extends AbstractLayoutStage

This class uses a customizable shuffle layout algorithm to recursively remove node overlaps from grouped graph structures. This class can be used as a LayoutStage in which case it will perform its work after the core layouter instance has performed its work.


Field Summary
 
Fields inherited from interface y.layout.Layouter
EDGE_ID_DPKEY, NODE_ID_DPKEY, SELECTED_EDGES, SELECTED_NODES
 
Constructor Summary
GroupedShuffleLayouter()
           
GroupedShuffleLayouter(Layouter core)
          Creates a new instance of GroupedShuffleLayouter The given core layouter instance will get to perform its work before the actual shuffling takes place.
 
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
 Layouter getShuffleLayouter()
          Returns the layouter instance, that will be used for shuffling (removing node overlaps).
 void setGroupBoundsCalculator(GroupBoundsCalculator groupBoundsCalculator)
          Sets the new GroupBoundsCalculator instance.
 void setShuffleLayouter(Layouter shuffleLayouter)
          Sets the layouter instance, that will be used for shuffling (removing node overlaps).
 
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

GroupedShuffleLayouter

public GroupedShuffleLayouter()

GroupedShuffleLayouter

public GroupedShuffleLayouter(Layouter core)
Creates a new instance of GroupedShuffleLayouter The given core layouter instance will get to perform its work before the actual shuffling takes place.

Method Detail

canLayout

public boolean canLayout(LayoutGraph graph)
Description copied from interface: Layouter
Returns 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.


doLayout

public void doLayout(LayoutGraph graph)
Description copied from interface: Layouter
Main layout routine that assigns new layout information to the given graph.


getGroupBoundsCalculator

public GroupBoundsCalculator getGroupBoundsCalculator()
Returns the currently installed GroupBoundsCalculator instance

Returns:
the GroupBoundsCalculator instance.

setGroupBoundsCalculator

public void setGroupBoundsCalculator(GroupBoundsCalculator groupBoundsCalculator)
Sets the new GroupBoundsCalculator instance.

Parameters:
groupBoundsCalculator - New GroupBoundsCalculator instance.

getShuffleLayouter

public Layouter getShuffleLayouter()
Returns the layouter instance, that will be used for shuffling (removing node overlaps).


setShuffleLayouter

public void setShuffleLayouter(Layouter shuffleLayouter)
Sets the layouter instance, that will be used for shuffling (removing node overlaps).


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