public final class LoggingStreamingContent extends Object implements StreamingContent
Implementation is not thread-safe.
|Constructor and Description|
|Modifier and Type||Method and Description|
Writes the byte content to the given output stream.
public LoggingStreamingContent(StreamingContent content, Logger logger, Level loggingLevel, int contentLoggingLimit)
content- streaming content
loggingLevel- logging level
contentLoggingLimit- maximum number of bytes to log or
0to avoid logging content
public void writeTo(OutputStream out) throws IOException
Implementations must not close the output stream, and instead should flush the output stream. Some callers may assume that the output stream has not been closed, and will fail to work if it has been closed.
Copyright © 2011–2020 Google. All rights reserved.