pub enum FezError {
Spawn {
program: String,
source: Error,
},
Io(Error),
Decode(Error),
Timeout,
BridgeClosed,
Problem(String),
Dbus {
name: String,
message: String,
},
NotFound(String),
Protected {
unit: String,
},
Aborted,
}Expand description
Every error fez can surface to the caller.
Variants§
Spawn
A child process (the bridge) could not be spawned.
Io(Error)
A generic I/O failure.
Decode(Error)
A protocol message could not be decoded.
Timeout
The bridge did not respond before the deadline.
BridgeClosed
The bridge connection was closed unexpectedly.
Problem(String)
The bridge reported a problem; the string is a problem kind.
Dbus
A D-Bus call returned an error.
NotFound(String)
The requested resource (e.g. a unit) does not exist.
Protected
A protected unit was targeted without --force.
Aborted
The user declined a confirmation prompt.
Implementations§
Trait Implementations§
Source§impl Error for FezError
impl Error for FezError
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 !RefUnwindSafe for FezError
impl !UnwindSafe for FezError
impl Freeze for FezError
impl Send for FezError
impl Sync for FezError
impl Unpin for FezError
impl UnsafeUnpin for FezError
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