|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.io.Writer
nl.tue.win.riaca.openmath.io.OMXMLWriter
Implements an outputstream that can write OpenMath objects as XML.
Field Summary | |
protected boolean |
mPrettyPrint
Stores if we should pretty-print. |
protected java.io.PrintWriter |
mPrintWriter
Stores the output-stream. |
protected boolean |
printOuterOMOBJ
Stores if we should drop the outer OMOBJ. |
protected static java.lang.String[] |
sOMObjects
Stores a static array with all the OpenMath element-names in use. |
Fields inherited from class java.io.Writer |
lock |
Constructor Summary | |
OMXMLWriter(java.io.Writer fWriter)
Constructor. |
|
OMXMLWriter(java.io.Writer fWriter,
boolean fPrettyPrint)
Constructor. |
|
OMXMLWriter(java.io.Writer writer,
boolean printPretty,
boolean printOuterOMOBJ)
Constructor. |
Method Summary | |
void |
close()
Close the stream, flushing it first. |
void |
flush()
Flush the stream. |
void |
write(char[] fCharacterBuffer,
int fOffset,
int fLength)
Write a portion of an array of characters. |
void |
write(int fInt)
Writes the specified byte to this output stream. |
void |
writeObject(OMObject fObject)
Write an OMObject. |
Methods inherited from class java.io.Writer |
write, write, write |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
protected static java.lang.String[] sOMObjects
protected boolean mPrettyPrint
protected boolean printOuterOMOBJ
protected java.io.PrintWriter mPrintWriter
Constructor Detail |
public OMXMLWriter(java.io.Writer fWriter)
fWriter
- the writer we actually use to write out.public OMXMLWriter(java.io.Writer fWriter, boolean fPrettyPrint)
fWriter
- the writer we actually use to write out.fPrettyPrint
- sets if we should pretty print the output.public OMXMLWriter(java.io.Writer writer, boolean printPretty, boolean printOuterOMOBJ)
writer
- the writer we actually use to write out.printPretty
- sets if we should pretty print the output.printOuterOMOBJ
- sets if we should print the outer OMOBJ.Method Detail |
public void write(int fInt) throws java.io.IOException
fInt
- the byte to write.
java.io.IOException
- when an I/O exception occurs.public void close() throws java.io.IOException
java.io.IOException
- when an I/O error occurs.public void write(char[] fCharacterBuffer, int fOffset, int fLength) throws java.io.IOException
fCharacterBuffer
- the buffer of characters to write.fOffset
- the offset in the character buffer.fLength
- the number of characters to write.
java.io.IOException
- when an I/O error occurs.public void flush() throws java.io.IOException
java.io.IOException
- when an I/O error occurs.public void writeObject(OMObject fObject)
fObject
- the OMObject to write out.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |