pub enum RecoverableFinishError<'reporter> {
Incomplete {
progress: Progress<'reporter>,
source: CompletionError,
},
Terminal(TerminalError),
}Expand description
Failure from checked finish while preserving a reusable progress operation.
Variants§
Incomplete
Completion validation failed and the operation remains reusable.
Fields
§
source: CompletionErrorFirst completion invariant that failed.
Terminal(TerminalError)
A terminal emission was attempted and failed permanently.
Implementations§
Source§impl<'reporter> RecoverableFinishError<'reporter>
impl<'reporter> RecoverableFinishError<'reporter>
Sourcepub fn completion_error(&self) -> Option<&CompletionError>
pub fn completion_error(&self) -> Option<&CompletionError>
Returns the completion error when validation failed.
Sourcepub fn into_progress(self) -> Result<Progress<'reporter>, TerminalError>
pub fn into_progress(self) -> Result<Progress<'reporter>, TerminalError>
Consumes an incomplete finish error and returns the reusable Progress.
Sourcepub fn into_parts(
self,
) -> Result<(Progress<'reporter>, CompletionError), TerminalError>
pub fn into_parts( self, ) -> Result<(Progress<'reporter>, CompletionError), TerminalError>
Consumes this error and returns its recoverable or terminal parts.
Trait Implementations§
Source§impl Debug for RecoverableFinishError<'_>
impl Debug for RecoverableFinishError<'_>
Source§impl Display for RecoverableFinishError<'_>
impl Display for RecoverableFinishError<'_>
Source§impl Error for RecoverableFinishError<'_>
impl Error for RecoverableFinishError<'_>
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the nested completion or terminal error.
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<'reporter> !RefUnwindSafe for RecoverableFinishError<'reporter>
impl<'reporter> !UnwindSafe for RecoverableFinishError<'reporter>
impl<'reporter> Freeze for RecoverableFinishError<'reporter>
impl<'reporter> Send for RecoverableFinishError<'reporter>
impl<'reporter> Sync for RecoverableFinishError<'reporter>
impl<'reporter> Unpin for RecoverableFinishError<'reporter>
impl<'reporter> UnsafeUnpin for RecoverableFinishError<'reporter>
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