diva.graph.basic
Class BasicGraphDemo
java.lang.Object
diva.graph.basic.BasicGraphDemo
public class BasicGraphDemo
- extends java.lang.Object
The graph demo demonstrates basic graph editing and layout
functionality, illustrates the key points of the graph
architecture. A graph is constructed programmatically, and can then
be edited interactively by the user. There are two views of the
graph: one which has an automatic layout algorithm applied each
time a new node is added, and one which uses a random or
user-driven layout.
The interaction and display in the graph editor, although currently
fairly simple, uses the features of the Diva canvas to good
effect. The use of two views of the graph highlights the
Swing-style model-view-controller architecture of the graph
package.
- Version:
- $Id: BasicGraphDemo.java 40701 2006-02-07 00:50:57Z cxh $
- Author:
- Michael Shilman, Steve Neuendorffer
- Accepted Rating:
Constructor Summary |
BasicGraphDemo(AppContext context)
Construct a new instance of the graph demo in a particular context. |
Method Summary |
static void |
main(java.lang.String[] argv)
Construct a new instance of graph demo, which does the work of
setting up the graphs and displaying itself. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
BasicGraphDemo
public BasicGraphDemo(AppContext context)
- Construct a new instance of the graph demo in a particular context.
- Parameters:
context
- The context in which the demo is constructed.
main
public static void main(java.lang.String[] argv)
- Construct a new instance of graph demo, which does the work of
setting up the graphs and displaying itself.
- Parameters:
argv
- Command line arguments, currently ignored.