class QCborError#

Synopsis#

Methods#

Note

This documentation may contain snippets that were automatically translated from C++ to Python. We always welcome contributions to the snippet translation. If you see an issue with the translation, you can also let us know by creating a ticket on https:/bugreports.qt.io/projects/PYSIDE

Detailed Description#

class Code#

This enum contains the possible error condition codes.

Constant

Description

QCborError.NoError

No error was detected.

QCborError.UnknownError

An unknown error occurred and no further details are available.

QCborError.AdvancePastEnd

next() was called but there are no more elements in the current context.

QCborError.InputOutputError

An I/O error with the QIODevice occurred.

QCborError.GarbageAtEnd

Data was found in the input stream after the last element.

QCborError.EndOfFile

The end of the input stream was unexpectedly reached while processing an element.

QCborError.UnexpectedBreak

The CBOR stream contains a Break where it is not allowed (data is corrupt and the error is not recoverable).

QCborError.UnknownType

The CBOR stream contains an unknown/unparsable Type (data is corrupt and the error is not recoverable).

QCborError.IllegalType

The CBOR stream contains a known type in a position it is not allowed to exist (data is corrupt and the error is not recoverable).

QCborError.IllegalNumber

The CBOR stream appears to be encoding a number larger than 64-bit (data is corrupt and the error is not recoverable).

QCborError.IllegalSimpleType

The CBOR stream contains a Simple Type encoded incorrectly (data is corrupt and the error is not recoverable).

QCborError.InvalidUtf8String

The CBOR stream contains a text string that does not decode properly as UTF-8 (data is corrupt and the error is not recoverable).

QCborError.DataTooLarge

CBOR string, map or array is too big and cannot be parsed by Qt (internal limitation, but the error is not recoverable).

QCborError.NestingTooDeep

Too many levels of arrays or maps encountered while processing the input (internal limitation, but the error is not recoverable).

QCborError.UnsupportedType

The CBOR stream contains a known type that the implementation does not support (internal limitation, but the error is not recoverable).

PySide6.QtCore.QCborError.c#
toString()#
Return type:

str

Returns a text string that matches the error code in this QCborError object.

Note: the string is not translated. Applications whose interface allow users to parse CBOR streams need to provide their own, translated strings.

See also

Code