pub enum DecodeError {
IO(Error),
GreaterLen,
SmallerLen,
PrimIndef,
TagTypeMismatch,
ExplicitTag,
IndefiniteLen,
IndefiniteLenEnd,
Custom(&'static str),
}Expand description
Errors that can occur while decoding an ASN.1 element.
Variants§
IO(Error)
Generic IO Error.
GreaterLen
Child element(s) decoded to greater length than the parent’s tag.
SmallerLen
Child element(s) decoded to smaller length than the parent’s tag.
PrimIndef
Primitive value encoded with an indefinite length.
TagTypeMismatch
Decoded tag does not match the expected tag for this type.
ExplicitTag
An explicit tag appeared where an Implicit tag was expected.
IndefiniteLen
Indefinite length encoding appeared when definite length encoding was expected.
IndefiniteLenEnd
Indefinite length encoding was started, but no terminator was found at the end.
Custom(&'static str)
Custom decoding error.
Trait Implementations§
Source§impl Debug for DecodeError
impl Debug for DecodeError
Source§impl From<DecodeError> for ParseResult
impl From<DecodeError> for ParseResult
Source§fn from(err: DecodeError) -> Self
fn from(err: DecodeError) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for DecodeError
impl !RefUnwindSafe for DecodeError
impl Send for DecodeError
impl Sync for DecodeError
impl Unpin for DecodeError
impl !UnwindSafe for DecodeError
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