public class JSONParseException extends SyntaxError:
Exception raised when a JSON document cannot be parsed or produced.
JSONParseException is used by the JSON parser for malformed documents, invalid escape sequences and truncated input. Serialization also raises it when an object graph contains a cycle, because JSON cannot represent cyclic references.
import klyn.io.json
try:
data = JSON.parseMap("""{"name": "Klyn"""")
catch error as JSONParseException:
print(error.message)| Modifier and Type | Member | Description |
|---|---|---|
| public | JSONParseExceptionJSONParseException(message as String = ""): |
Creates a JSON processing exception. |