fcmodeler.layout
Class AbstractLayout

java.lang.Object
  |
  +--fcmodeler.layout.AbstractLayout
All Implemented Interfaces:
diva.graph.layout.GlobalLayout
Direct Known Subclasses:
GEMLayout

public abstract class AbstractLayout
extends java.lang.Object
implements diva.graph.layout.GlobalLayout

... is ...

Since:
JDK1.3
Version:
$Revision: 1.1 $
Author:
Adam Tomjack

Field Summary
protected  java.util.Map _edgesToEdgeFigures
           
protected  FCModeler _fcmodeler
           
protected  java.util.List _nodes
           
 
Constructor Summary
AbstractLayout(FCModeler fcmodeler)
          Creates a new instance of AbstractLayout
 
Method Summary
abstract  void computeLayout()
          Call placeNode(...) to position each node.
 java.awt.geom.Rectangle2D getBoundingBox()
           
 FCModeler getFCModeler()
           
 diva.graph.model.Graph getGraph()
           
 diva.graph.layout.LayoutTarget getLayoutTarget()
           
 void layout()
           
 void layout(diva.graph.layout.LayoutTarget target, diva.graph.model.Graph graph)
           
 void placeNode(diva.graph.model.Node node, double x, double y)
           
 void setFCModeler(FCModeler fcmodeler)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

_fcmodeler

protected FCModeler _fcmodeler

_nodes

protected java.util.List _nodes

_edgesToEdgeFigures

protected java.util.Map _edgesToEdgeFigures
Constructor Detail

AbstractLayout

public AbstractLayout(FCModeler fcmodeler)
Creates a new instance of AbstractLayout
Method Detail

getFCModeler

public FCModeler getFCModeler()

getGraph

public diva.graph.model.Graph getGraph()

getLayoutTarget

public diva.graph.layout.LayoutTarget getLayoutTarget()

setFCModeler

public void setFCModeler(FCModeler fcmodeler)

layout

public void layout(diva.graph.layout.LayoutTarget target,
                   diva.graph.model.Graph graph)
Specified by:
layout in interface diva.graph.layout.GlobalLayout

placeNode

public void placeNode(diva.graph.model.Node node,
                      double x,
                      double y)

computeLayout

public abstract void computeLayout()
Call placeNode(...) to position each node. Do whatever is necessary to whatever type of edgeFigure you are using to position them.

layout

public void layout()

getBoundingBox

public java.awt.geom.Rectangle2D getBoundingBox()