|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.log.format.XMLFormatter
Basic XML formatter that writes out a basic XML-ified log event. Note that this formatter assumes that the category and context values will produce strings that do not need to be escaped in XML.
Constructor Summary | |
XMLFormatter()
|
Method Summary | |
java.lang.String |
format(LogEvent event)
Format log event into string. |
void |
setPrintCategory(boolean printCategory)
Print out category field to log. |
void |
setPrintContext(boolean printContext)
Print out context field to log. |
void |
setPrintException(boolean printException)
Print out exception field to log. |
void |
setPrintMessage(boolean printMessage)
Print out message field to log. |
void |
setPrintPriority(boolean printPriority)
Print out priority field to log. |
void |
setPrintRelativeTime(boolean printRelativeTime)
Print out relativeTime field to log. |
void |
setPrintTime(boolean printTime)
Print out time field to log. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public XMLFormatter()
Method Detail |
public void setPrintTime(boolean printTime)
printTime
- true to print time, false otherwisepublic void setPrintRelativeTime(boolean printRelativeTime)
printRelativeTime
- true to print relativeTime, false otherwisepublic void setPrintPriority(boolean printPriority)
printPriority
- true to print priority, false otherwisepublic void setPrintCategory(boolean printCategory)
printCategory
- true to print category, false otherwisepublic void setPrintContext(boolean printContext)
printContext
- true to print context, false otherwisepublic void setPrintMessage(boolean printMessage)
printMessage
- true to print message, false otherwisepublic void setPrintException(boolean printException)
printException
- true to print exception, false otherwisepublic java.lang.String format(LogEvent event)
format
in interface Formatter
event
- the event
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |