|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectscale.common.DisplayGraph
scale.visual.Vcg
public class Vcg
This class implements methods to generate commands to display a graph using vcg.
$Id: Vcg.java,v 1.5 2007-10-04 19:58:41 burrill Exp $
Copyright 2008 by the
Scale Compiler Group,
Department of Computer Science
University of Massachusetts,
Amherst MA. 01003, USA
All Rights Reserved.
| Field Summary |
|---|
| Fields inherited from class scale.common.DisplayGraph |
|---|
DISPLAY_EDGE_LABELS, outputPath, SHOW_ANNO, SHOW_CDG, SHOW_CLEF, SHOW_DD, SHOW_DEFUSE, SHOW_DOM, SHOW_EXPR, SHOW_EXPR_MASK, SHOW_HIGH_EXPR, SHOW_LOW_EXPR, SHOW_MAYUSE, SHOW_PDOM, SHOW_TYPE |
| Constructor Summary | |
|---|---|
Vcg()
|
|
| Method Summary | |
|---|---|
void |
addEdge(DisplayNode n1,
DisplayNode n2,
DColor color,
DEdge edgeAttributes,
java.lang.Object edgeInfo)
Add an edge to the graph from node n1 to node n2. |
void |
addNode(DisplayNode n)
Add a node to the graph. |
void |
closeWindow(java.lang.String context)
This closes an existing new visualization window. |
java.lang.String |
dashedEdgeAttr()
Return attribute for dashed edges. |
java.lang.String |
dottedEdgeAttr()
Retrn attribute for dotted edges. |
void |
interact()
Respond to interative events with this display. |
void |
newGraph(java.lang.String context,
boolean top)
Initialize for a new graph. |
void |
openWindow(java.lang.String context,
java.lang.String title,
int graphAttributes)
This opens a new visualization window. |
void |
terminate()
Terminates the visualizer process. |
boolean |
visited(DisplayNode n)
Return true if the node has been processed. |
boolean |
windowExists(java.lang.String context)
Return true if the window for the given context still exists. |
| Methods inherited from class scale.common.DisplayGraph |
|---|
addDisplayString, getVisualizer, initColors, setOutputPath, setVisualizer |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public Vcg()
| Method Detail |
|---|
public void newGraph(java.lang.String context,
boolean top)
newGraph in class DisplayGraphcontext - is the name associated with the graphtop - if true places the root node at the top of the displaypublic java.lang.String dottedEdgeAttr()
public java.lang.String dashedEdgeAttr()
public boolean visited(DisplayNode n)
visited in class DisplayGraphn - is the node to checkpublic void addNode(DisplayNode n)
addNode in class DisplayGraphn - is the node
public void addEdge(DisplayNode n1,
DisplayNode n2,
DColor color,
DEdge edgeAttributes,
java.lang.Object edgeInfo)
| bits | use |
|---|---|
| 5-0 | color |
| 6 | type: normal, backedge |
| 8-7 | pattern: solid, dashed, dotted
addEdge in class DisplayGraphn1 - is the first noden2 - is the second nodecolor - specifies the edge coloredgeAttributes - specifies the type, and form of the edgeedgeInfo - is additional information about the edgepublic void terminate()
terminate in class DisplayGraph
public void openWindow(java.lang.String context,
java.lang.String title,
int graphAttributes)
openWindow in class DisplayGraphcontext - is the user defined string to distinguish between
different windowstitle - is title for the windowgraphAttributes - species attributes for the graphDisplayGraph.newGraph(java.lang.String, boolean)public void closeWindow(java.lang.String context)
closeWindow in class DisplayGraphcontext - is the user defined string to distinguish between
different windowsDisplayGraph.newGraph(java.lang.String, boolean)public boolean windowExists(java.lang.String context)
windowExists in class DisplayGraphpublic void interact()
interact in class DisplayGraph
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||