Struct qt_core::q_cbor_error::Code

source ·
pub struct Code(/* private fields */);
Expand description

This enum contains the possible error condition codes.

C++ enum: QCborError::Code.

C++ documentation:

This enum contains the possible error condition codes.

Implementations§

source§

impl Code

source

pub fn to_int(&self) -> c_int

source§

impl Code

source

pub const UnknownError: Code = _

An unknown error occurred and no further details are available. (C++ enum variant: UnknownError = 1)

source

pub const AdvancePastEnd: Code = _

QCborStreamReader::next() was called but there are no more elements in the current context. (C++ enum variant: AdvancePastEnd = 3)

source

pub const InputOutputError: Code = _

An I/O error with the QIODevice occurred. (C++ enum variant: InputOutputError = 4)

source

pub const GarbageAtEnd: Code = _

Data was found in the input stream after the last element. (C++ enum variant: GarbageAtEnd = 256)

source

pub const EndOfFile: Code = _

The end of the input stream was unexpectedly reached while processing an element. (C++ enum variant: EndOfFile = 257)

source

pub const UnexpectedBreak: Code = _

The CBOR stream contains a Break where it is not allowed (data is corrupt and the error is not recoverable). (C++ enum variant: UnexpectedBreak = 258)

source

pub const UnknownType: Code = _

The CBOR stream contains an unknown/unparseable Type (data is corrupt and the and the error is not recoverable). (C++ enum variant: UnknownType = 259)

source

pub const IllegalType: Code = _

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). (C++ enum variant: IllegalType = 260)

source

pub const IllegalNumber: Code = _

The CBOR stream appears to be encoding a number larger than 64-bit (data is corrupt and the error is not recoverable). (C++ enum variant: IllegalNumber = 261)

source

pub const IllegalSimpleType: Code = _

The CBOR stream contains a Simple Type encoded incorrectly (data is corrupt and the error is not recoverable). (C++ enum variant: IllegalSimpleType = 262)

source

pub const InvalidUtf8String: Code = _

The CBOR stream contains a text string that does not decode properly as UTF-8 (data is corrupt and the error is not recoverable). (C++ enum variant: InvalidUtf8String = 516)

source

pub const DataTooLarge: Code = _

CBOR string, map or array is too big and cannot be parsed by Qt (internal limitation, but the error is not recoverable). (C++ enum variant: DataTooLarge = 1024)

source

pub const NestingTooDeep: Code = _

Too many levels of arrays or maps encountered while processing the input (internal limitation, but the error is not recoverable). (C++ enum variant: NestingTooDeep = 1025)

source

pub const UnsupportedType: Code = _

The CBOR stream contains a known type that the implementation does not support (internal limitation, but the error is not recoverable). (C++ enum variant: UnsupportedType = 1026)

source

pub const NoError: Code = _

No error was detected. (C++ enum variant: NoError = 0)

Trait Implementations§

source§

impl Clone for Code

source§

fn clone(&self) -> Code

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Code

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl From<Code> for c_int

source§

fn from(value: Code) -> Self

Converts to this type from the input type.
source§

impl From<i32> for Code

source§

fn from(value: c_int) -> Self

Converts to this type from the input type.
source§

impl PartialEq for Code

source§

fn eq(&self, other: &Code) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Copy for Code

source§

impl Eq for Code

source§

impl StructuralEq for Code

source§

impl StructuralPartialEq for Code

Auto Trait Implementations§

§

impl RefUnwindSafe for Code

§

impl Send for Code

§

impl Sync for Code

§

impl Unpin for Code

§

impl UnwindSafe for Code

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T, U> CastInto<U> for T
where U: CastFrom<T>,

source§

unsafe fn cast_into(self) -> U

Performs the conversion. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> StaticUpcast<T> for T

source§

unsafe fn static_upcast(ptr: Ptr<T>) -> Ptr<T>

Convert type of a const pointer. Read more
source§

impl<T> ToOwned for T
where T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.