#[non_exhaustive]pub enum DecodeReason {
Truncated,
BadLength,
IndefiniteLength,
UnexpectedTag,
MissingField,
BadValue,
TooDeep,
TrailingBytes,
NotAscii,
NotProcessBusFrame,
}Expand description
Why a decode failed.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Truncated
Fewer bytes than the encoding requires.
BadLength
A BER length that cannot be represented or is not allowed here.
IndefiniteLength
Indefinite-length encoding, which this decoder does not accept.
UnexpectedTag
A tag that is not valid at this position.
MissingField
A required element is missing.
BadValue
A primitive value is malformed (empty integer, bad float exponent width, …).
TooDeep
Nesting deeper than the configured limit.
TrailingBytes
Trailing bytes after a complete element where none are allowed.
NotAscii
A value that is not ASCII in a VisibleString.
NotProcessBusFrame
The Ethernet frame is not a GOOSE/SV frame (wrong EtherType) or too short.
Trait Implementations§
Source§impl Clone for DecodeReason
impl Clone for DecodeReason
impl Copy for DecodeReason
Source§impl Debug for DecodeReason
impl Debug for DecodeReason
impl Eq for DecodeReason
Source§impl PartialEq for DecodeReason
impl PartialEq for DecodeReason
impl StructuralPartialEq for DecodeReason
Auto Trait Implementations§
impl Forget for DecodeReason
impl Freeze for DecodeReason
impl Move for DecodeReason
impl RefUnwindSafe for DecodeReason
impl Send for DecodeReason
impl Sync for DecodeReason
impl Unpin for DecodeReason
impl UnsafeUnpin for DecodeReason
impl UnwindSafe for DecodeReason
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