org.apache.log4j.pattern
Class PatternParser
java.lang.Object
|
+--org.apache.log4j.pattern.PatternParser
- public final class PatternParser
- extends Object
Most of the work of the PatternLayout
class
is delegated to the PatternParser class.
It is this class that parses conversion patterns and creates
a chained list of PatternConverters
.
- Since:
- 1.3
- Author:
- James P. Cakalic, Ceki Gülcü, Anders Kristensen, Paul Smith, Curt Arnold
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
getPatternLayoutRules
public static Map getPatternLayoutRules()
- Get standard format specifiers for PatternLayout.
- Returns:
- read-only map of format converter classes keyed by format specifier strings.
getFileNamePatternRules
public static Map getFileNamePatternRules()
- Get standard format specifiers for rolling file appender file specification.
- Returns:
- read-only map of format converter classes keyed by format specifier strings.
parse
public static void parse(String pattern,
List patternConverters,
List formattingInfos,
Map converterRegistry,
Map rules,
ULogger logger)
- Parse a format specifier.
- Parameters:
pattern
- pattern to parse.patternConverters
- list to receive pattern converters.formattingInfos
- list to receive field specifiers corresponding to pattern converters.converterRegistry
- map of user-supported pattern converters keyed by format specifier, may be null.rules
- map of stock pattern converters keyed by format specifier.logger
- logger to receive parser warnings, may be null.
Copyright © 2000-2006 Apache Software Foundation.
Licensed under the Apache License, Version 2.0.