Constructor and Description |
---|
DOT() |
Modifier and Type | Method and Description |
---|---|
static DOTComponent |
createDOTComponent(Reader r)
Creates a
DOTComponent that displays the result of rendering a DOT description
read from a Reader . |
static Writer |
createDotWriter(boolean modal)
Creates a Writer that can be used to write a DOT description to.
|
static Process |
executeDOT(String format,
String... additionalOpts) |
static void |
renderDOT(File dotFile,
boolean modal)
Renders a GraphVIZ description from a string and displays it in a
Swing window.
|
static void |
renderDOT(Reader r,
boolean modal)
Renders a GraphVIZ description and displays it in a Swing window.
|
static void |
renderDOT(String dotText,
boolean modal)
Renders a GraphVIZ description from a string and displays it in a
Swing window.
|
static void |
renderDOTExternal(File dotFile,
String format)
Renders a GraphVIZ description from a file, using an external program
for displaying.
|
static void |
renderDOTExternal(Reader r,
String format)
Renders a GraphVIZ description, using an external program for displaying.
|
static void |
renderDOTExternal(String dotText,
String format)
Renders a GraphVIZ description from a string, using an external program
for displaying.
|
static BufferedImage |
renderDOTImage(File dotFile)
Reads a DOT description from a file and returns the PNG rendering result as a
BufferedImage . |
static BufferedImage |
renderDOTImage(Reader dotReader)
Reads a DOT description from a reader and returns the PNG rendering result as a
BufferedImage . |
static BufferedImage |
renderDOTImage(String dotText)
Reads a DOT description from a string and returns the PNG rendering result as a
BufferedImage . |
static void |
runDOT(File dotFile,
String format,
File out)
Invokes the DOT utility on a file, producing an output file.
|
static InputStream |
runDOT(File dotFile,
String format,
String... additionalOpts)
Invokes the DOT utility on a file.
|
static void |
runDOT(Reader r,
String format,
File out)
Invokes the GraphVIZ DOT utility for rendering graphs, writing output
to the specified file.
|
static InputStream |
runDOT(Reader r,
String format,
String... additionalOpts)
Invokes the GraphVIZ DOT utility for rendering graphs.
|
static void |
runDOT(String dotText,
String format,
File out)
Invokes the DOT utility on a string, producing an output file.
|
static InputStream |
runDOT(String dotText,
String format,
String... additionalOpts)
Invokes the DOT utility on a string.
|
public DOT()
public static Process executeDOT(String format, String... additionalOpts) throws IOException
IOException
public static InputStream runDOT(Reader r, String format, String... additionalOpts) throws IOException
r
- the reader from which the GraphVIZ description is obtained.format
- the output format, as understood by the dot utility, e.g.,
png, ps, ...IOException
- if reading from the specified reader fails.public static InputStream runDOT(String dotText, String format, String... additionalOpts) throws IOException
#runDOT(Reader, String)
.IOException
public static InputStream runDOT(File dotFile, String format, String... additionalOpts) throws IOException
#runDOT(Reader, String)
.IOException
public static void runDOT(Reader r, String format, File out) throws IOException
r
- the reader from which the GraphVIZ description is read.format
- the output format to produce.out
- the file to which the output is written.IOException
- if an I/O error occurs reading from the given input
or writing to the output file.public static void runDOT(String dotText, String format, File out) throws IOException
runDOT(Reader, String, File)
.IOException
public static void runDOT(File dotFile, String format, File out) throws IOException, FileNotFoundException
runDOT(Reader, String, File)
.IOException
FileNotFoundException
public static void renderDOTExternal(Reader r, String format)
Desktop.open(File)
method.r
- the reader from which the GraphVIZ description is read.format
- the output format, as understood by the dot utility, e.g.,
png, ps, ...public static void renderDOTExternal(String dotText, String format)
renderDOTExternal(Reader, String)
.public static void renderDOTExternal(File dotFile, String format) throws FileNotFoundException
renderDOTExternal(Reader, String)
.FileNotFoundException
- if the specified file was not found.public static void renderDOT(Reader r, boolean modal)
r
- the reader from which the description is obtained.modal
- whether or not the dialog should be modal.public static void renderDOT(String dotText, boolean modal)
renderDOT(Reader, boolean)
.public static void renderDOT(File dotFile, boolean modal) throws FileNotFoundException
renderDOT(Reader, boolean)
.FileNotFoundException
- if the specified file was not found.public static BufferedImage renderDOTImage(Reader dotReader) throws IOException
BufferedImage
.dotReader
- the reader from which to read the descriptionIOException
- if reading from the reader fails, or the pipe to the
DOT process breaks.public static BufferedImage renderDOTImage(String dotText) throws IOException
BufferedImage
.dotText
- the DOT descriptionIOException
- if the pipe to the DOT process breaks.public static BufferedImage renderDOTImage(File dotFile) throws IOException
BufferedImage
.dotFile
- the file containing the DOT descriptionIOException
- if reading from the file fails or the pipe to the DOT process breaks.public static DOTComponent createDOTComponent(Reader r)
DOTComponent
that displays the result of rendering a DOT description
read from a Reader
.r
- the reader to read frompublic static Writer createDotWriter(boolean modal)
modal
- whether or not this window is modal (if set to true, calls to
Writer.close()
will block.Copyright © 2015. All Rights Reserved.