Skip to main content

CodecError

Enum CodecError 

Source
pub enum CodecError {
Show 18 variants Io(Error), FieldResolution(FieldResolutionError), FieldValue(FieldValueError), MissingBitWidth { field_name: &'static str, }, InvalidBitWidth { field_name: &'static str, bit_width: u32, }, InvalidLength { field_name: &'static str, expected: usize, actual: usize, }, NumericOverflow { field_name: &'static str, bit_width: u32, }, ConstantMismatch { field_name: &'static str, constant: &'static str, }, InvalidConstant { field_name: &'static str, constant: &'static str, }, UnsupportedVarintWidth { field_name: &'static str, }, VarintOverflow { field_name: &'static str, value: u64, }, UnsupportedVersion { box_type: FourCc, version: u8, }, UnknownBoxType { box_type: FourCc, }, InvalidUtf8 { field_name: &'static str, }, InvalidUnboundedLength { field_name: &'static str, bit_width: u32, remaining_bits: u64, }, UnsupportedFixedLengthString { field_name: &'static str, }, InvalidBoxAlignment { box_type: FourCc, bit_count: u64, }, Overrun { box_type: FourCc, payload_size: u64, bit_count: u64, },
}
Expand description

Errors raised while encoding or decoding descriptor-backed boxes.

Variants§

§

Io(Error)

§

FieldResolution(FieldResolutionError)

§

FieldValue(FieldValueError)

§

MissingBitWidth

Fields

§field_name: &'static str
§

InvalidBitWidth

Fields

§field_name: &'static str
§bit_width: u32
§

InvalidLength

Fields

§field_name: &'static str
§expected: usize
§actual: usize
§

NumericOverflow

Fields

§field_name: &'static str
§bit_width: u32
§

ConstantMismatch

Fields

§field_name: &'static str
§constant: &'static str
§

InvalidConstant

Fields

§field_name: &'static str
§constant: &'static str
§

UnsupportedVarintWidth

Fields

§field_name: &'static str
§

VarintOverflow

Fields

§field_name: &'static str
§value: u64
§

UnsupportedVersion

Fields

§box_type: FourCc
§version: u8
§

UnknownBoxType

Fields

§box_type: FourCc
§

InvalidUtf8

Fields

§field_name: &'static str
§

InvalidUnboundedLength

Fields

§field_name: &'static str
§bit_width: u32
§remaining_bits: u64
§

UnsupportedFixedLengthString

Fields

§field_name: &'static str
§

InvalidBoxAlignment

Fields

§box_type: FourCc
§bit_count: u64
§

Overrun

Fields

§box_type: FourCc
§payload_size: u64
§bit_count: u64

Trait Implementations§

Source§

impl Debug for CodecError

Source§

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

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

impl Display for CodecError

Source§

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

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

impl Error for CodecError

Source§

fn source(&self) -> Option<&(dyn Error + 'static)>

Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§

fn description(&self) -> &str

👎Deprecated since 1.42.0:

use the Display impl or to_string()

1.0.0 · Source§

fn cause(&self) -> Option<&dyn Error>

👎Deprecated since 1.33.0:

replaced by Error::source, which can support downcasting

Source§

fn provide<'a>(&'a self, request: &mut Request<'a>)

🔬This is a nightly-only experimental API. (error_generic_member_access)
Provides type-based access to context intended for error reports. Read more
Source§

impl From<CodecError> for EditError

Source§

fn from(value: CodecError) -> Self

Converts to this type from the input type.
Source§

impl From<CodecError> for ExtractError

Source§

fn from(value: CodecError) -> Self

Converts to this type from the input type.
Source§

impl From<CodecError> for MuxError

Available on crate feature mux only.
Source§

fn from(error: CodecError) -> Self

Converts to this type from the input type.
Source§

impl From<CodecError> for ProbeError

Source§

fn from(value: CodecError) -> Self

Converts to this type from the input type.
Source§

impl From<CodecError> for RewriteError

Source§

fn from(value: CodecError) -> Self

Converts to this type from the input type.
Source§

impl From<CodecError> for SidxAnalysisError

Source§

fn from(value: CodecError) -> Self

Converts to this type from the input type.
Source§

impl From<CodecError> for SidxPlanError

Source§

fn from(value: CodecError) -> Self

Converts to this type from the input type.
Source§

impl From<CodecError> for SidxRewriteError

Source§

fn from(value: CodecError) -> Self

Converts to this type from the input type.
Source§

impl From<CodecError> for WalkError

Source§

fn from(value: CodecError) -> Self

Converts to this type from the input type.
Source§

impl From<Error> for CodecError

Source§

fn from(error: Error) -> Self

Converts to this type from the input type.
Source§

impl From<FieldResolutionError> for CodecError

Source§

fn from(error: FieldResolutionError) -> Self

Converts to this type from the input type.
Source§

impl From<FieldValueError> for CodecError

Source§

fn from(error: FieldValueError) -> Self

Converts to this type from the input type.

Auto Trait Implementations§

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> 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> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T> ToString for T
where T: Display + ?Sized,

Source§

fn to_string(&self) -> String

Converts the given value to a String. Read more
Source§

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

Source§

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>,

Source§

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.