pub enum NpyError {
InvalidMagicNumber([u8; 6]),
InvalidVersion([u8; 2]),
IoError(Error),
Utf8Error(FromUtf8Error),
ParsingMismatch {
expected: Vec<u8>,
found: Vec<u8>,
expected_str: String,
found_str: String,
},
InvalidAlignment,
}
Variants
InvalidMagicNumber([u8; 6])
Magic number did not match the expected value.
InvalidVersion([u8; 2])
IoError(Error)
Error from opening a file, reading values, etc.
Utf8Error(FromUtf8Error)
Error from converting header bytes to a String.
ParsingMismatch
InvalidAlignment
Unexpected alignment for Endian.
Trait Implementations
sourceimpl Error for NpyError
impl Error for NpyError
sourcefn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
The lower-level source of this error, if any. Read more
1.0.0 · sourcefn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
sourceimpl From<FromUtf8Error> for NpyError
impl From<FromUtf8Error> for NpyError
sourcefn from(e: FromUtf8Error) -> Self
fn from(e: FromUtf8Error) -> Self
Converts to this type from the input type.
Auto Trait Implementations
impl !RefUnwindSafe for NpyError
impl Send for NpyError
impl Sync for NpyError
impl Unpin for NpyError
impl !UnwindSafe for NpyError
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more