public static parse(notnull json as String) as Object
Parses JSON text into its natural Klyn representation.
JSON objects become maps, arrays become array lists, and scalar values retain their corresponding primitive type. Integer tokens produce Int within its signed 32-bit range and Long otherwise. Tokens with a decimal point or exponent produce Double.
| Parameter | Description |
|---|---|
json | JSON document to parse. |
Parsed map, list, scalar value, or null.
value = JSON.parse("""{"numerator": 1, "denominator": 3}""")
assert value is SortedMap
assert JSON.parse("2147483648") is Long