EDU.auburn.VGJ.algorithm.tree
Class TreeAlgorithm

java.lang.Object
  extended byEDU.auburn.VGJ.algorithm.tree.TreeAlgorithm
All Implemented Interfaces:
GraphAlgorithm

public class TreeAlgorithm
extends java.lang.Object
implements GraphAlgorithm

An algorithm for laying out a graph as a tree.

Here is the source.


Constructor Summary
TreeAlgorithm(char orientation)
           
 
Method Summary
 java.lang.String compute(Graph graph, GraphUpdate update)
          Apply the algorithm to graph.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TreeAlgorithm

public TreeAlgorithm(char orientation)
Method Detail

compute

public java.lang.String compute(Graph graph,
                                GraphUpdate update)
Description copied from interface: GraphAlgorithm
Apply the algorithm to graph. The return value should be null if successful, and an error message if unsuccessful.

Specified by:
compute in interface GraphAlgorithm
Parameters:
update - an object that allows the display to be updated from within the algorithm
See Also:
GraphUpdate