Package io.karatelabs.js
Class JsonParser
java.lang.Object
io.karatelabs.js.JsonParser
Strict RFC 8259 / ECMA-404 JSON parser. Public entry:
parse(String).
Returns Map/List/String/Integer/Long/
BigInteger/Double/Boolean/null. Throws
JsErrorException (SyntaxError shape) on invalid input.
Numeric narrowing: integer values in int range → Integer;
integer values fitting in long → Long; larger integers →
BigInteger; any literal with a fractional part or exponent →
Double. See JsonParserTest for the pinned contract.
Designed to be allocated per call (JsonParser.ParseState is a private,
non-static inner class); the parse entry point is thread-safe by
construction — no shared mutable state.
-
Method Summary
-
Method Details
-
parse
-