parseJson

fun parseJson(input: String): Json

Parses JSON from input string. Returns Json sealed interface.

For example: parseJson(""" "name": "Alexey", "age": 28 """) will return JsonObject instance which contains JsonString and JsonNumber in the values map.

JSON properties can be accessed by json.string("name"), json.int("age") accessors.

Throws

if parsing error is occurred