public class GraphvizGenerator extends java.lang.Object
| Constructor and Description |
|---|
GraphvizGenerator()
Create a new generator that uses
dot and expects it to be on
the path. |
GraphvizGenerator(java.lang.String layoutEnginePath)
Create a new generator by specifying the executable of the layout engine.
|
| Modifier and Type | Method and Description |
|---|---|
void |
generateFile(java.lang.String description,
java.io.File file,
EGraphvizOutputFormat format)
Export a graph to a file.
|
java.lang.String |
generateFileAndImageMap(java.lang.String description,
java.io.File file,
EGraphvizOutputFormat format)
Export a graph to a file and return the HTML image map code.
|
java.awt.image.BufferedImage |
generateImage(java.lang.String description)
Generate an image from a graph description.
|
public GraphvizGenerator()
dot and expects it to be on
the path.public GraphvizGenerator(java.lang.String layoutEnginePath)
dot is not on the path or if another
layout engine like neato should be used.layoutEnginePath - path to layout engine excutablepublic void generateFile(java.lang.String description, java.io.File file, EGraphvizOutputFormat format) throws java.io.IOException, GraphvizException
description - the graph descriptionfile - the file to export to.format - the export format.java.io.IOException - if an I/O problem occurrs.GraphvizException - if Graphviz produced an error (exit code != 0)public java.lang.String generateFileAndImageMap(java.lang.String description, java.io.File file, EGraphvizOutputFormat format) throws java.io.IOException, GraphvizException
description - the graph descriptionfile - the file to export to.format - the export format.java.io.IOException - if an I/O problem occurrs.GraphvizException - if Graphviz produced an error (exit code != 0)public java.awt.image.BufferedImage generateImage(java.lang.String description) throws java.io.IOException, GraphvizException
description - the graph description.java.io.IOException - if an I/O problem occurrs.GraphvizException - if Graphviz produced an error (exit code != 0)