Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.log4j.helpers
Class PatternParser

    java.lang.Object
      org.apache.log4j.helpers.PatternParser

    public class PatternParser

extends java.lang.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 `OptionConverters`.

Since:
  0.8.2
Author:
  James P. Cakalic, Ceki Gülcü, Anders Kristensen

Field Summary
`protected java.lang.StringBuffer` | `currentLiteral`
`protected FormattingInfo` | `formattingInfo`
`protected int` | `i`
`protected java.lang.String` | `pattern`
`protected int` | `patternLength`

Constructor Summary
`PatternParser(java.lang.String pattern)`

Method Summary
`protected void` | `addConverter(PatternConverter pc)`
`protected java.lang.String` | `extractOption()`
`protected int` | `extractPrecisionOption()` The option is expected to be in decimal and positive.
`protected void` | `finalizeConverter(char c)`
`PatternConverter` | `parse()`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### currentLiteral

    protected java.lang.StringBuffer currentLiteral

### patternLength

    protected int patternLength

### i

    protected int i

### formattingInfo

    protected FormattingInfo formattingInfo

### pattern

    protected java.lang.String pattern

Constructor Detail

### PatternParser

    public PatternParser(java.lang.String pattern)

Method Detail

### extractOption

    protected java.lang.String extractOption()

### extractPrecisionOption

    protected int extractPrecisionOption()

  The option is expected to be in decimal and positive. In case of error, zero is returned.

### parse

    public PatternConverter parse()

### finalizeConverter

    protected void finalizeConverter(char c)

### addConverter

    protected void addConverter(PatternConverter pc)

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 1999-2007 Apache Software Foundation. All Rights Reserved.