Enum binary_util::error::BinaryError
source · pub enum BinaryError {
OutOfBounds(usize, usize, &'static str),
EOF(usize),
RecoverableKnown(String),
RecoverableUnknown,
}
👎Deprecated: This module is deprecated in favor of std::io::Error.
Expand description
An enum consisting of a Binary Error (recoverable)
Variants§
OutOfBounds(usize, usize, &'static str)
👎Deprecated: This module is deprecated in favor of std::io::Error.
Offset is out of bounds
Tuple Values:
usize
= Given Offset.usize
= Stream length.&'static str
= Message to add on to the error.
EOF(usize)
👎Deprecated: This module is deprecated in favor of std::io::Error.
Similar to OutOfBounds
except it means;
the stream tried to read more than possible.
Tuple Values:
usize
= Stream length.
RecoverableKnown(String)
👎Deprecated: This module is deprecated in favor of std::io::Error.
A known error that was recoverable to safely proceed the stack.
RecoverableUnknown
👎Deprecated: This module is deprecated in favor of std::io::Error.
An unknown error occurred, but it wasn’t critical, we can safely proceed on the stack.
Implementations§
source§impl BinaryError
impl BinaryError
pub fn get_message(&self) -> String
👎Deprecated: This module is deprecated in favor of std::io::Error.
Trait Implementations§
source§impl Debug for BinaryError
impl Debug for BinaryError
source§impl Display for BinaryError
impl Display for BinaryError
source§impl From<Error> for BinaryError
impl From<Error> for BinaryError
source§impl PartialEq<BinaryError> for BinaryError
impl PartialEq<BinaryError> for BinaryError
source§fn eq(&self, other: &BinaryError) -> bool
fn eq(&self, other: &BinaryError) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.impl StructuralPartialEq for BinaryError
Auto Trait Implementations§
impl RefUnwindSafe for BinaryError
impl Send for BinaryError
impl Sync for BinaryError
impl Unpin for BinaryError
impl UnwindSafe for BinaryError
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