org.jscience.ml.openmath.util
Class PrettyPrint

java.lang.Object
  extended by org.jscience.ml.openmath.util.PrettyPrint

public class PrettyPrint
extends java.lang.Object

Pretty prints an OpenMath object.


Constructor Summary
PrettyPrint()
           
 
Method Summary
 java.io.InputStream getInputStream()
          Gets the input-stream.
 java.io.OutputStream getOutputStream()
          Gets the output-stream.
static void main(java.lang.String[] arguments)
          Invokes the pretty-printer stand-alone.
 void prettyPrint()
          Validates the document.
 void setInputStream(java.io.InputStream newInputStream)
          Sets the input-stream.
 void setOutputStream(java.io.OutputStream newOutputStream)
          Sets the output-stream.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PrettyPrint

public PrettyPrint()
Method Detail

setOutputStream

public void setOutputStream(java.io.OutputStream newOutputStream)
Sets the output-stream.

Parameters:
newOutputStream - set the output stream.

getOutputStream

public java.io.OutputStream getOutputStream()
Gets the output-stream.

Returns:
the output stream.

setInputStream

public void setInputStream(java.io.InputStream newInputStream)
Sets the input-stream.

Parameters:
newInputStream - set the input stream.

getInputStream

public java.io.InputStream getInputStream()
Gets the input-stream.

Returns:
the input stream.

prettyPrint

public void prettyPrint()
                 throws java.lang.Exception
Validates the document.

Throws:
java.lang.Exception - throw if we cannot pretty print the document for some obscure reason.

main

public static void main(java.lang.String[] arguments)
Invokes the pretty-printer stand-alone.

Parameters:
arguments - the arguments passed to the program.