pub enum ContainerEncodeError {
MetadataTooLarge(usize),
BinaryCodec(BinaryError),
UnsupportedMode(LnmpFileMode),
UnsupportedFlags(u16),
ReservedFlags(u16),
ChecksumFlagMissingHints,
InvalidMetadataLength {
mode: LnmpFileMode,
expected: usize,
actual: usize,
},
InvalidMetadataValue {
mode: LnmpFileMode,
field: &'static str,
value: u8,
},
}Expand description
Errors produced while emitting .lnmp containers.
Variants§
MetadataTooLarge(usize)
Metadata payload cannot fit in the header field.
BinaryCodec(BinaryError)
Binary encoder failed.
UnsupportedMode(LnmpFileMode)
Mode is not supported for encoding helpers.
UnsupportedFlags(u16)
Requested flags require capabilities that are not available yet.
ReservedFlags(u16)
Reserved flags are set in a v1 container (only checksum is allowed).
ChecksumFlagMissingHints
Checksum flag set but record lacks checksum hints.
InvalidMetadataLength
Metadata length does not satisfy mode requirements.
Fields
§
mode: LnmpFileModeMode provided.
InvalidMetadataValue
Metadata field contains a value that is not allowed for this mode.
Trait Implementations§
Source§impl Debug for ContainerEncodeError
impl Debug for ContainerEncodeError
Source§impl Display for ContainerEncodeError
impl Display for ContainerEncodeError
Source§impl Error for ContainerEncodeError
impl Error for ContainerEncodeError
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()
Auto Trait Implementations§
impl Freeze for ContainerEncodeError
impl RefUnwindSafe for ContainerEncodeError
impl Send for ContainerEncodeError
impl Sync for ContainerEncodeError
impl Unpin for ContainerEncodeError
impl UnwindSafe for ContainerEncodeError
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