Package com.sun.identity.log.handlers
Class ELFFormatter
- java.lang.Object
-
- java.util.logging.Formatter
-
- com.sun.identity.log.handlers.ELFFormatter
-
public class ELFFormatter extends Formatter
This Formatter is the custom defined Formatter for DSAME which formats the logRecord according to ELF. For details of ELF specification pls refer www.w3.org/TR/WD-logfile.html. This Formatter will put the version number and Fields as the first 2 lines and the data corresponding to each field follows. If a field is not selected a "-" is put.
-
-
Constructor Summary
Constructors Constructor Description ELFFormatter()returns a ELF Formatter
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Stringformat(LogRecord logRecord)Format the given record as per ELF and return a formatted string.StringgetHead(Handler handler)According to ELF, the log file should start with a #Version which specifies the ELF version used followed by a #Fields line which specifies all the fields that are being logged.StringgetTail(Handler handler)Returns an empty string.-
Methods inherited from class java.util.logging.Formatter
formatMessage
-
-
-
-
Method Detail
-
format
public String format(LogRecord logRecord)
Format the given record as per ELF and return a formatted string.For ELF Specifications refer
- www.w3.org/TR/WD-logfile.html
-
getHead
public String getHead(Handler handler)
According to ELF, the log file should start with a #Version which specifies the ELF version used followed by a #Fields line which specifies all the fields that are being logged.ELFFormatter uses this method to return back the header containing these two lines. FileHandler checks if the header is already written, if not uses this method to get the header and puts it at the beginning of the file.
-
-