org.globus.cog.gui.grapheditor.util
Class GraphToXML

java.lang.Object
  extended byorg.globus.cog.gui.grapheditor.util.GraphToXML

public class GraphToXML
extends Object

Saves a hypergraph into an XML file


Constructor Summary
GraphToXML()
           
 
Method Summary
static String repeat(char c, int count)
           
static String serialize(Object o)
          Serializes an arbitrary object to a Base 64 string.
static void write(GraphComponent c, Writer writer, int indentation, boolean hidden)
           
static String writeProperties(GraphComponent c, Writer writer, boolean hidden)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

GraphToXML

public GraphToXML()
Method Detail

write

public static void write(GraphComponent c,
                         Writer writer,
                         int indentation,
                         boolean hidden)
                  throws IOException
Parameters:
c - The topmost component of the hypergraph
writer - The writer for the XML to go to
indentation - the level of indentation (generates easy to read XML files... if there is such a thing)
hidden - indicates whether hidden properties should be saved
Throws:
IOException

writeProperties

public static String writeProperties(GraphComponent c,
                                     Writer writer,
                                     boolean hidden)
                              throws IOException
Throws:
IOException

repeat

public static String repeat(char c,
                            int count)

serialize

public static String serialize(Object o)
                        throws Exception
Serializes an arbitrary object to a Base 64 string.

Parameters:
o -
Returns:
Throws:
Exception