Package eu.bandm.tools.util
Class PrintWriter_flushing
java.lang.Object
java.io.Writer
java.io.PrintWriter
eu.bandm.tools.util.PrintWriter_flushing
- All Implemented Interfaces:
Closeable
,Flushable
,Appendable
,AutoCloseable
Print writer which flushes the unerlying output stream after each print.
Convenient for debugging purpose, due to inconsistent java lib
flushing strategy.
Since the java io architecture has grown historically, the
PrintWriter.flush()
strategy is not always "fast enough" for
debugging purposes. Therefore this class patches the
PrintWriter.print(String)
and
PrintWriter.println(String)
methods to call flush()
immediately and "hard" as soon as their output is delivered.
Attention, beside these both methods no other output functions have been patched/overridden!
-
Field Summary
Fields inherited from class java.io.PrintWriter
out
-
Constructor Summary
-
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, printf, printf, println, println, println, println, println, println, println, println, println, setError, write, write, write, write, write
Methods inherited from class java.io.Writer
nullWriter
-
Constructor Details
-
PrintWriter_flushing
Eviden.. -
PrintWriter_flushing
Evident..
-
-
Method Details
-
print
- Overrides:
print
in classPrintWriter
-
println
- Overrides:
println
in classPrintWriter
-