public class SiteGraph extends Object
SiteGraph is a tool that renders out GraphViz-generated images depicting your Struts-powered web application's flow. SiteGraph requires GraphViz be installed and that the "dot" executable be in your command path. You can find GraphViz at http://www.graphviz.org.
If you wish to use SiteGraph through its API rather than through the command line,
you can do that as well. All you need to do is create a new SiteGraph instance,
optionally specify a Writer
to output the dot content to, and then call
prepare()
.
Constructor and Description |
---|
SiteGraph(String configDir,
String views,
String output,
String namespace) |
Modifier and Type | Method and Description |
---|---|
static void |
main(String[] args) |
void |
prepare()
Prepares the dot generated content and writes out to the provided writer
object.
|
void |
render()
Invokes the dot command, cause GraphViz to render out.dot in the form of out.gif,
located in the specified output directory.
|
void |
setWriter(Writer writer) |
public static void main(String[] args) throws IOException
IOException
public void prepare()
FileWriter
pointing to "out.dot"
in the specified output directly shall be used.public void render()
public void setWriter(Writer writer)
Copyright © 2000–2023 Apache Software Foundation. All rights reserved.