pub enum TaskError<E> {
Fsm(E),
Join(JoinError),
}Expand description
Error type returned by the FSM background task.
This enum distinguishes between logical errors returned by your FSM handlers and runtime failures of the Tokio task itself (e.g., panics or cancellation).
§Type Parameters
E: The logical error type defined in yourimplblock viatype Error = ...;.
Variants§
Fsm(E)
The FSM handler returned a logical error.
Join(JoinError)
The background task failed due to a panic or external cancellation.
Trait Implementations§
Source§impl<E> Error for TaskError<E>
impl<E> Error for TaskError<E>
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<E> Freeze for TaskError<E>where
E: Freeze,
impl<E> !RefUnwindSafe for TaskError<E>
impl<E> Send for TaskError<E>where
E: Send,
impl<E> Sync for TaskError<E>where
E: Sync,
impl<E> Unpin for TaskError<E>where
E: Unpin,
impl<E> !UnwindSafe for TaskError<E>
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