pub enum NcsHeaderError {
TooShort(usize),
InvalidMagic,
InvalidMarker(u8),
}Expand description
Errors returned while decoding the fixed NCS header.
Variants§
TooShort(usize)
The provided byte slice was shorter than the fixed header.
InvalidMagic
The file prefix did not match the expected NCS V1.0 signature.
InvalidMarker(u8)
The binary marker byte after the text header was not B.
Trait Implementations§
Source§impl Clone for NcsHeaderError
impl Clone for NcsHeaderError
Source§fn clone(&self) -> NcsHeaderError
fn clone(&self) -> NcsHeaderError
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for NcsHeaderError
impl Debug for NcsHeaderError
Source§impl Display for NcsHeaderError
impl Display for NcsHeaderError
Source§impl Error for NcsHeaderError
impl Error for NcsHeaderError
1.30.0 · 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 From<NcsHeaderError> for NcsReadError
impl From<NcsHeaderError> for NcsReadError
Source§fn from(value: NcsHeaderError) -> Self
fn from(value: NcsHeaderError) -> Self
Converts to this type from the input type.
Source§impl PartialEq for NcsHeaderError
impl PartialEq for NcsHeaderError
impl Eq for NcsHeaderError
impl StructuralPartialEq for NcsHeaderError
Auto Trait Implementations§
impl Freeze for NcsHeaderError
impl RefUnwindSafe for NcsHeaderError
impl Send for NcsHeaderError
impl Sync for NcsHeaderError
impl Unpin for NcsHeaderError
impl UnsafeUnpin for NcsHeaderError
impl UnwindSafe for NcsHeaderError
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.