public class XMLDecoder extends Object implements Decoder
Constructor and Description |
---|
XMLDecoder()
Create new instance.
|
XMLDecoder(Component o)
Create new instance.
|
Modifier and Type | Method and Description |
---|---|
org.apache.log4j.spi.LoggingEvent |
decode(String data)
Converts the string data into an XML Document, and then soaks out the
relevant bits to form a new LoggingEvent instance which can be used
by any Log4j element locally.
|
Vector |
decode(URL url)
Decodes a File into a Vector of LoggingEvents.
|
Vector |
decodeEvents(String document)
Decodes a String representing a number of events into a
Vector of LoggingEvents.
|
void |
setAdditionalProperties(Map properties)
Sets an additionalProperty map, where each Key/Value pair is
automatically added to each LoggingEvent as it is decoded.
|
public XMLDecoder(Component o)
o
- ownerpublic XMLDecoder()
public void setAdditionalProperties(Map properties)
setAdditionalProperties
in interface Decoder
properties
- additional propertiespublic Vector decode(URL url) throws IOException
decode
in interface Decoder
url
- the url of a file containing events to decodeIOException
- if IO error during processing.public Vector decodeEvents(String document)
decodeEvents
in interface Decoder
document
- to decode events frompublic org.apache.log4j.spi.LoggingEvent decode(String data)
Copyright © 2013 The Apache Software Foundation. All Rights Reserved.