Class JsonReader

java.lang.Object
org.apache.logging.log4j.kit.json.JsonReader

public final class JsonReader extends Object
A simple JSON parser mapping tokens to basic Java types.

The type mapping is as follows:

  • objects are mapped to LinkedHashMap<String,Object>
  • arrays are mapped to LinkedList
  • strings are mapped to String with proper Unicode and escape character conversion
  • true, false, and null are mapped to their Java counterparts
  • floating point numbers are mapped to BigDecimal
  • integral numbers are mapped to either primitive types (int, long) or BigInteger

This code is heavily influenced by the reader of mjson.

  • Method Details