ca.sqlpower.architect.layout
Class ArchitectGridLayout

java.lang.Object
  extended by ca.sqlpower.architect.layout.AbstractLayout
      extended by ca.sqlpower.architect.layout.ArchitectGridLayout
All Implemented Interfaces:
ArchitectLayout

public class ArchitectGridLayout
extends AbstractLayout


Field Summary
 
Fields inherited from class ca.sqlpower.architect.layout.AbstractLayout
frame
 
Constructor Summary
ArchitectGridLayout()
           
 
Method Summary
 void done()
          Interrupts the algorithm and node bounds in a consistent state.
 boolean isDone()
          Returns true iff the layout is finished.
 void nextFrame()
          Updates all the node locations to correspond with the positions they should have in the next frame.
 void setup(java.util.Collection<? extends LayoutNode> nodes, java.util.Collection<? extends LayoutEdge> edges, java.awt.Rectangle rect)
          Sets up the layout algoritm.
 
Methods inherited from class ca.sqlpower.architect.layout.AbstractLayout
getNewArea, getProperty, setProperty
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ArchitectGridLayout

public ArchitectGridLayout()
Method Detail

setup

public void setup(java.util.Collection<? extends LayoutNode> nodes,
                  java.util.Collection<? extends LayoutEdge> edges,
                  java.awt.Rectangle rect)
Description copied from interface: ArchitectLayout
Sets up the layout algoritm. You have to call this before attempting to use an ArchitectLayout instance to perform a layout. TODO change the Rectangle into a point. This should indicate where to start but the layout should determine dimensions

Specified by:
setup in interface ArchitectLayout
Overrides:
setup in class AbstractLayout
Parameters:
nodes - The list of entities to be placed on

done

public void done()
Description copied from interface: ArchitectLayout
Interrupts the algorithm and node bounds in a consistent state.


isDone

public boolean isDone()
Description copied from interface: ArchitectLayout
Returns true iff the layout is finished.

Returns:
true if the layout algorithm is finished with the layout, false otherwise

nextFrame

public void nextFrame()
Description copied from interface: ArchitectLayout
Updates all the node locations to correspond with the positions they should have in the next frame.



Copyright © 2003-2007 SQL Power Group Inc. www.sqlpower.ca