pub struct OSError(/* private fields */);
Expand description
The raw os error
This is a wrapper around io::Error
providing explain()
method
Note: you need to explain as fast as possible, because during explain library makes some probes for different things in filesystem, and if anything changes it may give incorrect results.
You should always explain()
the errors, unless you are trying lots of
mounts for bruteforcing or other similar thing and you are concerned of
performance. Usually library does stat()
and similar things which are
much faster than mount anyway. Also explaining is zero-cost in the success
path.
Implementations§
Trait Implementations§
Source§impl Error for OSError
impl Error for OSError
Source§fn cause(&self) -> Option<&dyn StdError>
fn cause(&self) -> Option<&dyn StdError>
👎Deprecated since 1.33.0: replaced by Error::source, which can support downcasting
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 OSError
impl !RefUnwindSafe for OSError
impl !Send for OSError
impl !Sync for OSError
impl Unpin for OSError
impl !UnwindSafe for OSError
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