data.exporters
Class ExporterTreeML
java.lang.Object
data.exporters.ExporterTreeML
public class ExporterTreeML
- extends java.lang.Object
This class allow export Tree objects as TreeML files. It's mainly used to be
the input of Prefuse visualitzation, but it could have other uses...
- Version:
- 1.0
- Author:
- Oscar Flores
Method Summary |
static java.io.File |
writeTreeML(Tree t)
Creates a temporal file containing the exported tree in TreeML format |
private static void |
writeTreeML(TreeNode t,
int level,
Matrix mat,
java.io.OutputStreamWriter out)
Writes recursively all the tree nodes |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ExporterTreeML
public ExporterTreeML()
writeTreeML
public static java.io.File writeTreeML(Tree t)
throws DataException
- Creates a temporal file containing the exported tree in TreeML format
- Parameters:
t
- Tree to export
- Returns:
- Temporal file with TreeML tree
- Throws:
DataException
writeTreeML
private static void writeTreeML(TreeNode t,
int level,
Matrix mat,
java.io.OutputStreamWriter out)
throws java.io.IOException
- Writes recursively all the tree nodes
- Parameters:
t
- Current TreeNodelevel
- Current identation levelmat
- Reference Matrixout
- OutputStreamWriter of temp File
- Throws:
java.io.IOException