public class Log.Entry
extends Object
Constructor and Description |
---|
Entry(int type,
String pre,
String msg)
Instantiate an Entry for the Log. The timestamp is initialized
automatically to the current time and date.
|
Entry(int type,
String pre,
java.time.ZonedDateTime dt,
String msg)
Instantiate an Entry for the Log using a specific timestamp.
|
Modifier and Type | Method and Description |
---|---|
String |
toString()
Provide log-suitable-formatted output version of this object. If the
pre-amble portion is NULL, then it is excluded (along with its delimiting
space). If the message portion is NULL, then it is excluded (along with
its delimiting space).
|
String |
toStringN()
Provide log-suitable-formatted output version of this object. If the
pre-amble portion is NULL, then it is excluded (along with its delimiting
space). If the message portion is NULL, then it is excluded (along with
its delimiting space).
|
public Entry(int type, String pre, String msg)
type
- Must be Log.LOG (akin to stdout) or Log.ERR (akin to stderr)pre
- Log pre-amble (the portion before the timestamp)msg
- Log message (the portion after the timestamp)TypeNotPresentException
- If the type is invalidpublic Entry(int type, String pre, java.time.ZonedDateTime dt, String msg)
type
- Must be Log.LOG (akin to stdout) or Log.ERR (akin to stderr)pre
- Log pre-amble (the portion before the timestamp)dt
- Timestampmsg
- Log message (the portion after the timestamp)TypeNotPresentException
- If the type is invalidpublic String toString()
toString
in class Object
public String toStringN()