Package org.djutils.logger
Class LoggerTest.StringWriter
java.lang.Object
org.djutils.logger.LoggerTest.StringWriter
- All Implemented Interfaces:
Writer
- Enclosing class:
- LoggerTest
protected static class LoggerTest.StringWriter extends Object implements Writer
...
-
Constructor Summary
Constructors Modifier Constructor Description protected
StringWriter()
-
Method Summary
Modifier and Type Method Description void
clear()
Nullify the last logged message (so we can distinguish a newly received message even when it is the empty string.void
close()
void
flush()
Set<LogEntryValue>
getRequiredLogEntryValues()
String
getResult()
Return the last logged message.void
init(Configuration configuration)
void
write(LogEntry logEntry)
-
Constructor Details
-
StringWriter
protected StringWriter()
-
-
Method Details
-
getRequiredLogEntryValues
- Specified by:
getRequiredLogEntryValues
in interfaceWriter
-
init
-
write
-
flush
-
close
-
getResult
Return the last logged message.- Returns:
- String; the last logged message
-
clear
public void clear()Nullify the last logged message (so we can distinguish a newly received message even when it is the empty string.
-