com.pushtotest.testmaker.gui.EdenLib
Class JTextAreaStream

java.lang.Object
  extended by java.io.OutputStream
      extended by com.pushtotest.testmaker.gui.EdenLib.JTextAreaStream
All Implemented Interfaces:
java.io.Closeable, java.io.Flushable

public class JTextAreaStream
extends java.io.OutputStream

Creates a java.io.OutputStream that we use to redirect System.out and System.err. Taken from a posting at: http://forum.java.sun.com/thread.jsp?thread=411458&forum=54&message=1810092


Field Summary
protected  javax.swing.JTextArea writeTo
           
 
Constructor Summary
JTextAreaStream(javax.swing.JTextArea writeTo)
           
 
Method Summary
 void close()
           
 void flush()
           
 void write(byte[] b)
           
 void write(byte[] b, int off, int len)
           
 void write(int b)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

writeTo

protected javax.swing.JTextArea writeTo
Constructor Detail

JTextAreaStream

public JTextAreaStream(javax.swing.JTextArea writeTo)
Method Detail

close

public void close()
Specified by:
close in interface java.io.Closeable
Overrides:
close in class java.io.OutputStream

flush

public void flush()
Specified by:
flush in interface java.io.Flushable
Overrides:
flush in class java.io.OutputStream

write

public void write(byte[] b)
Overrides:
write in class java.io.OutputStream

write

public void write(byte[] b,
                  int off,
                  int len)
Overrides:
write in class java.io.OutputStream

write

public void write(int b)
Specified by:
write in class java.io.OutputStream