public final class ConsoleWriter extends AbstractFormatPatternWriter
The error output stream will be used for log entries with the severity level warning and error. The standard output stream will used for all other log entries.
Constructor and Description |
---|
ConsoleWriter() |
ConsoleWriter(Map<String,String> properties) |
Modifier and Type | Method and Description |
---|---|
void |
close()
Closes the writer.
|
void |
flush()
Outputs buffered log entries immediately.
|
Collection<LogEntryValue> |
getRequiredLogEntryValues()
Gets all log entry values that are required for rendering a log entry by the defined format pattern.
|
void |
write(LogEntry logEntry)
Outputs a given log entry.
|
createByteArrayWriter, getCharset, getFileName, render
public Collection<LogEntryValue> getRequiredLogEntryValues()
AbstractFormatPatternWriter
getRequiredLogEntryValues
in interface Writer
getRequiredLogEntryValues
in class AbstractFormatPatternWriter
public void write(LogEntry logEntry)
Writer
logEntry
- Log entry to outputpublic void flush()
Writer
public void close()
Writer
Copyright © 2020. All rights reserved.