All Packages Class Hierarchy This Package Previous Next Index
Interface fr.inria.openmath.omapi.TreePrinter
- public interface TreePrinter
Basic interface for OpenMath tree printers.
All OpenMath tree printers must implement this basic interface: it allows
applications to output OpenMath object trees on a character stream.
- See Also:
- TreePrinterImpl
-
endPrint()
- Does what is needed when print has been completed.
-
getPrinter()
- Allows an application to get the current printer.
-
printTree(Node)
- Print a whole tree.
-
setPrinter(Printer)
- Allows an application to set the printer used during tree traversal.
setPrinter
public abstract void setPrinter(Printer output) throws OMException
- Allows an application to set the printer used during tree traversal.
Set the printer.
The printer may be changed during print.
But, this is possible only between two OpenMath object output.
Or else a OMException is thrown, and current output stream is not
changed.
- Parameters:
- output - the new printer
- Throws: OMException
- Any OpenMath exception.
- See Also:
- XMLPrinter, BinaryPrinter, HumanPrinter
getPrinter
public abstract Printer getPrinter()
- Allows an application to get the current printer.
Get the current printer
- Returns:
- the current printer (or NULL if none is set)
printTree
public abstract void printTree(Node root) throws OMException
- Print a whole tree.
Print a whole tree.
- Parameters:
- root - The root node of the tree to print.
- Throws: OMException
- Any OpenMath exception.
endPrint
public abstract void endPrint() throws OMException
- Does what is needed when print has been completed.
It must be called when no more print is to be done on this printer.
- Throws: OMException
- Any OpenMath exception.
- See Also:
- Symbol
All Packages Class Hierarchy This Package Previous Next Index