Package com.icegreen.greenmail.util
Class LoggingInputStream
java.lang.Object
java.io.InputStream
java.io.FilterInputStream
com.icegreen.greenmail.util.LoggingInputStream
- All Implemented Interfaces:
Closeable,AutoCloseable
Logs stream for debugging purpose on DEBUG level.
-
Field Summary
FieldsFields inherited from class java.io.FilterInputStream
in -
Constructor Summary
ConstructorsConstructorDescriptionLoggingInputStream(InputStream is, String prefix) Creates an input stream filter built on top of the specified underlying input stream. -
Method Summary
Methods inherited from class java.io.FilterInputStream
available, mark, markSupported, read, reset, skipMethods inherited from class java.io.InputStream
nullInputStream, readAllBytes, readNBytes, readNBytes, skipNBytes, transferTo
-
Field Details
-
loggingBuffer
-
-
Constructor Details
-
LoggingInputStream
Creates an input stream filter built on top of the specified underlying input stream.- Parameters:
is- the underlying input stream to be assigned to the fieldFilterInputStream.infor later use, ornullif this instance is to be created without an underlying stream.prefix- a log message prefix, eg 'c: ' for server side protocol trace input.
-
-
Method Details
-
read
- Overrides:
readin classFilterInputStream- Throws:
IOException
-
read
- Overrides:
readin classFilterInputStream- Throws:
IOException
-
close
- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Overrides:
closein classFilterInputStream- Throws:
IOException
-