QJsonParseError

The QJsonParseError class is used to report errors during JSON parsing. More

Inheritance diagram of PySide2.QtCore.QJsonParseError

Synopsis

Functions

Detailed Description

See also

JSON Support in Qt JSON Save Game Example

class QJsonParseError

QJsonParseError(QJsonParseError)

Parameters

QJsonParseErrorQJsonParseError

PySide2.QtCore.QJsonParseError.ParseError

This enum describes the type of error that occurred during the parsing of a JSON document.

Constant

Description

QJsonParseError.NoError

No error occurred

QJsonParseError.UnterminatedObject

An object is not correctly terminated with a closing curly bracket

QJsonParseError.MissingNameSeparator

A comma separating different items is missing

QJsonParseError.UnterminatedArray

The array is not correctly terminated with a closing square bracket

QJsonParseError.MissingValueSeparator

A colon separating keys from values inside objects is missing

QJsonParseError.IllegalValue

The value is illegal

QJsonParseError.TerminationByNumber

The input stream ended while parsing a number

QJsonParseError.IllegalNumber

The number is not well formed

QJsonParseError.IllegalEscapeSequence

An illegal escape sequence occurred in the input

QJsonParseError.IllegalUTF8String

An illegal UTF8 sequence occurred in the input

QJsonParseError.UnterminatedString

A string wasn’t terminated with a quote

QJsonParseError.MissingObject

An object was expected but couldn’t be found

QJsonParseError.DeepNesting

The JSON document is too deeply nested for the parser to parse it

QJsonParseError.DocumentTooLarge

The JSON document is too large for the parser to parse it

QJsonParseError.GarbageAtEnd

The parsed document contains additional garbage characters at the end

PySide2.QtCore.QJsonParseError.offset
PySide2.QtCore.QJsonParseError.error
PySide2.QtCore.QJsonParseError.errorString()
Return type

unicode

Returns the human-readable message appropriate to the reported JSON parsing error.

See also

error