|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.log5j.format.SimpleFormat
public final class SimpleFormat
A simple, fixed format for log messages.
SimpleFormat has two configuration properties:
arrayDepth. An integer value that specifies the number
of levels of nesting of arrays to recurse through when printing the contents
of arrays.traceThrowable. if set to true, any Throwable
object will have its full stack trace logged. The rules for setting the value
of traceThrowable are those of the
Boolean.valueOf(String) method.
| Constructor Summary | |
|---|---|
SimpleFormat(java.util.Properties properties)
The standard constructor takes as arguments the properties that may affect how SimpleFormat formats log lines. |
|
| Method Summary | |
|---|---|
java.lang.String |
format(java.lang.String logName,
java.lang.String levelName,
java.lang.Object... objects)
Return a formatted String derived from a number of objects or primitives to append to a logger output stream. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public SimpleFormat(java.util.Properties properties)
SimpleFormat formats log lines.
SimpleFormat recognises the following properties;
arrayDepth: The number of levels of nesting of
arrays to recurse through when printing the contents of arraystraceThrowable: Print out the entire stack trace of
any Throwable if true
properties - the properties of this format object.| Method Detail |
|---|
public java.lang.String format(java.lang.String logName,
java.lang.String levelName,
java.lang.Object... objects)
Format
format in interface FormatlogName - the name of the loggerlevelName - the logging level nameobjects - the array of objects or primitives providing Strings to
log
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||