pub enum Fault {
Denied,
ConfirmationRequired,
Blocked,
Busy,
}Expand description
A fault of the device about the user.
Variants§
Denied
The user lacks the right for the action (606).
ConfirmationRequired
The action needs a second factor (866).
Blocked
Confirmations are blocked after failed ones (867).
Busy
Another confirmation is running (868).
Implementations§
Source§impl Fault
impl Fault
Sourcepub fn of(error: &Error) -> Option<Self>
pub fn of(error: &Error) -> Option<Self>
The fault of an error, if the device answered with one.
Sourcepub fn retry_after(self) -> Option<Duration>
pub fn retry_after(self) -> Option<Duration>
The longest time to wait before trying again, if waiting helps.
Sourcepub fn is_temporary(self) -> bool
pub fn is_temporary(self) -> bool
Whether the device holds back all confirmations for a while, so that the next calls fail the same way.
Trait Implementations§
impl Copy for Fault
impl Eq for Fault
impl StructuralPartialEq for Fault
Auto Trait Implementations§
impl Forget for Fault
impl Freeze for Fault
impl Move for Fault
impl RefUnwindSafe for Fault
impl Send for Fault
impl Sync for Fault
impl Unpin for Fault
impl UnsafeUnpin for Fault
impl UnwindSafe for Fault
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