Package jflex.logging
Class StdOutWriter
java.lang.Object
java.io.Writer
java.io.PrintWriter
jflex.logging.StdOutWriter
- All Implemented Interfaces:
Closeable
,Flushable
,Appendable
,AutoCloseable
Convenience class for JFlex stdout, redirects output to a TextArea if in GUI mode.
- Version:
- JFlex 1.8.2
- Author:
- Gerwin Klein
-
Field Summary
Fields inherited from class java.io.PrintWriter
out
-
Constructor Summary
ConstructorsConstructorDescriptionA StdOutWriter, attached to System.out, no gui modeStdOutWriter
(OutputStream out) A StdOutWrite, attached to the specified output stream, no gui mode -
Method Summary
Methods inherited from class java.io.PrintWriter
append, append, append, checkError, clearError, close, flush, format, format, print, print, print, print, print, print, print, print, print, printf, printf, println, println, println, println, println, println, println, println, println, setError, write, write
Methods inherited from class java.io.Writer
nullWriter
-
Constructor Details
-
StdOutWriter
public StdOutWriter()A StdOutWriter, attached to System.out, no gui mode -
StdOutWriter
A StdOutWrite, attached to the specified output stream, no gui mode- Parameters:
out
- aOutputStream
object.
-
-
Method Details
-
setGUIMode
Set the TextArea to write text to. Will continue to write to System.out if text isnull
.- Parameters:
text
- the TextArea to write to
-
write
public void write(int c) Write a single character.- Overrides:
write
in classPrintWriter
- Parameters:
c
- a int.
-
write
public void write(char[] buf, int off, int len) Write a portion of an array of characters.
- Overrides:
write
in classPrintWriter
-
write
Write a portion of a string.
- Overrides:
write
in classPrintWriter
-
println
public void println()Begin a new line. Which actual character/s is/are written depends on the runtime platform.- Overrides:
println
in classPrintWriter
-