Evolvica Core API Version 0.6.2
Last Modified: June 29 2004

org.evolvica.engine
Class AlgorithmWriter

java.lang.Object
  extended byorg.evolvica.engine.AlgorithmWriter

public class AlgorithmWriter
extends java.lang.Object

Algorithm writer.

Since:
0.4.0
Version:
$Revision: 1.13 $ $Date: 2004/05/26 11:58:22 $
Author:
Andreas Rummler

Constructor Summary
AlgorithmWriter()
           
 
Method Summary
 org.w3c.dom.Document createDocument(IAlgorithm algorithm)
          Creates a XML document from a given algorithm.
 void write(org.w3c.dom.Document document, java.io.OutputStream stream)
          Writes an XML algorithm document to an output stream.
 void write(IAlgorithm algorithm, java.io.OutputStream stream)
          Writes an algorithm to an output stream.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AlgorithmWriter

public AlgorithmWriter()
Method Detail

write

public void write(org.w3c.dom.Document document,
                  java.io.OutputStream stream)
           throws javax.xml.transform.TransformerConfigurationException,
                  javax.xml.transform.TransformerException
Writes an XML algorithm document to an output stream.

Parameters:
document - document to write
stream - output stream to write to
Throws:
javax.xml.transform.TransformerConfigurationException - thrown if XML transformation fails
javax.xml.transform.TransformerException - thrown if XML transformation fails

write

public void write(IAlgorithm algorithm,
                  java.io.OutputStream stream)
           throws SerializationException,
                  javax.xml.transform.TransformerConfigurationException,
                  javax.xml.transform.TransformerException
Writes an algorithm to an output stream.

Parameters:
algorithm - algorithm to write
stream - output stream to write to
Throws:
SerializationException - thrown in case the XML document could not be created
javax.xml.transform.TransformerConfigurationException - thrown if XML transformation fails
javax.xml.transform.TransformerException - thrown if XML transformation fails

createDocument

public org.w3c.dom.Document createDocument(IAlgorithm algorithm)
                                    throws SerializationException
Creates a XML document from a given algorithm.

Parameters:
algorithm - algorithm to be transformed
Returns:
XML document containing the algorithm description
Throws:
SerializationException - thrown in case the document could not be created

Evolvica Core API Version 0.6.2
Last Modified: June 29 2004

Copyright © 2000-2004 Technical University of Ilmenau, Department Electronic Circuits and Systems