Package com.icegreen.greenmail.util
Class LoggingOutputStream
java.lang.Object
java.io.OutputStream
java.io.FilterOutputStream
com.icegreen.greenmail.util.LoggingOutputStream
- All Implemented Interfaces:
Closeable,Flushable,AutoCloseable
Logs stream for debugging purpose on DEBUG level.
-
Field Summary
FieldsFields inherited from class java.io.FilterOutputStream
out -
Constructor Summary
ConstructorsConstructorDescriptionLoggingOutputStream(OutputStream out, String prefix) Creates an output stream filter built on top of the specified underlying output stream. -
Method Summary
Methods inherited from class java.io.FilterOutputStream
write, writeMethods inherited from class java.io.OutputStream
nullOutputStream
-
Field Details
-
loggingBuffer
-
-
Constructor Details
-
LoggingOutputStream
Creates an output stream filter built on top of the specified underlying output stream.- Parameters:
out- the underlying output stream to be assigned to the fieldFilterOutputStream.outfor later use, ornullif this instance is to be created without an underlying stream.prefix- a log message prefix, eg 's: ' for server side protocol trace output.
-
-
Method Details
-
write
- Overrides:
writein classFilterOutputStream- Throws:
IOException
-
flush
- Specified by:
flushin interfaceFlushable- Overrides:
flushin classFilterOutputStream- Throws:
IOException
-
close
- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Overrides:
closein classFilterOutputStream- Throws:
IOException
-