org.freehep.util.io
Class JavaArrayWriter

java.lang.Object
  extended by java.io.Writer
      extended by java.io.PrintWriter
          extended by org.freehep.util.io.IndentPrintWriter
              extended by org.freehep.util.io.JavaArrayWriter
All Implemented Interfaces:
Closeable, Flushable, Appendable, FinishableOutputStream

public class JavaArrayWriter
extends IndentPrintWriter
implements FinishableOutputStream

The JavaArrayOutputStream writes out the text in java to compile into a byte array.

Author:
Mark Donszelmann

Field Summary
 
Fields inherited from class java.io.PrintWriter
out
 
Fields inherited from class java.io.Writer
lock
 
Constructor Summary
JavaArrayWriter(Writer out, String arrayName, String author)
           
 
Method Summary
 void close()
           
 void finish()
          Finishes the current outputstream (compresses, flushes, caluclates CRC) and writes whatever is left in the buffers, but does not close the stream.
 void write(int b)
           
 
Methods inherited from class org.freehep.util.io.IndentPrintWriter
getIndent, getIndentString, indent, outdent, print, print, print, print, print, print, print, print, print, println, setIndent, setIndentString
 
Methods inherited from class java.io.PrintWriter
append, append, append, checkError, clearError, flush, format, format, printf, printf, println, println, println, println, println, println, println, println, println, setError, write, write, write, write
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JavaArrayWriter

public JavaArrayWriter(Writer out,
                       String arrayName,
                       String author)
Method Detail

write

public void write(int b)
Overrides:
write in class PrintWriter

finish

public void finish()
Description copied from interface: FinishableOutputStream
Finishes the current outputstream (compresses, flushes, caluclates CRC) and writes whatever is left in the buffers, but does not close the stream.

Specified by:
finish in interface FinishableOutputStream

close

public void close()
Specified by:
close in interface Closeable
Overrides:
close in class PrintWriter


Copyright © 2012. All Rights Reserved.