public class DebugWriter
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
private java.text.DateFormat |
simpleDateFormat
A formatter for timestamps.
|
private java.lang.Object |
sync
The object for synchronizing messages.
|
private java.io.Writer |
writer
The
Writer to write to. |
Constructor and Description |
---|
DebugWriter(java.io.Writer writer)
Creates a new instance.
|
Modifier and Type | Method and Description |
---|---|
void |
debugProtocolWrite(java.lang.CharSequence str)
Writes a message to the debug protocol.
|
void |
debugProtocolWrite(java.lang.CharSequence str,
java.lang.Throwable throwable)
Writes a message to the debug protocol including a throwable.
|
@NotNull private final java.text.DateFormat simpleDateFormat
@NotNull private final java.lang.Object sync
@NotNull private final java.io.Writer writer
Writer
to write to.public DebugWriter(@NotNull java.io.Writer writer)
writer
- the writer to write topublic void debugProtocolWrite(@NotNull java.lang.CharSequence str)
str
- the message to writepublic void debugProtocolWrite(@NotNull java.lang.CharSequence str, @NotNull java.lang.Throwable throwable)
str
- the message to writethrowable
- the throwable to log