pub enum Error<E> {
Malformed(Error),
InvalidTag,
Content(E),
}Expand description
Possible errors when decoding tagged content.
Variants§
Malformed(Error)
Tag is malformed.
InvalidTag
Tag does not match the expected tag.
Content(E)
Error decoding the tagged content.
Implementations§
Trait Implementations§
Source§impl<E: Error + 'static> Error for Error<E>
impl<E: Error + 'static> Error for Error<E>
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
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
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
Source§impl<E> From<EndOfInput> for Error<E>
impl<E> From<EndOfInput> for Error<E>
Source§fn from(_: EndOfInput) -> Self
fn from(_: EndOfInput) -> Self
Converts to this type from the input type.
Source§impl<E> From<InvalidHeader> for Error<E>
impl<E> From<InvalidHeader> for Error<E>
Source§fn from(_: InvalidHeader) -> Self
fn from(_: InvalidHeader) -> Self
Converts to this type from the input type.
Source§impl<E: Ord> Ord for Error<E>
impl<E: Ord> Ord for Error<E>
Source§impl<E: PartialOrd> PartialOrd for Error<E>
impl<E: PartialOrd> PartialOrd for Error<E>
impl<E: Copy> Copy for Error<E>
impl<E: Eq> Eq for Error<E>
impl<E> StructuralPartialEq for Error<E>
Auto Trait Implementations§
impl<E> Freeze for Error<E>where
E: Freeze,
impl<E> RefUnwindSafe for Error<E>where
E: RefUnwindSafe,
impl<E> Send for Error<E>where
E: Send,
impl<E> Sync for Error<E>where
E: Sync,
impl<E> Unpin for Error<E>where
E: Unpin,
impl<E> UnwindSafe for Error<E>where
E: UnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more