pub enum DictateFailure {
HashMismatch {
path: PathBuf,
expected: String,
actual: String,
size: u64,
},
Cancelled {
kept: u64,
total: u64,
},
Other {
message: String,
},
}Expand description
Why preflight stopped.
Every variant ends the run: there is no degraded dictation to fall back to, so the screen names the way out and forge quits.
Variants§
HashMismatch
A file is the right length and the wrong bytes. Reported rather
than repaired - discarding a multi-gigabyte file somebody put
there is not forge’s call, and size is what makes that
sentence concrete rather than abstract on screen.
Cancelled
The user asked preflight to stop. kept of total bytes are on
disk for the file that was in flight, which the screen says
before forge goes. total is carried so the bar can stay a
fraction: a full bar beside cancelled reads as finished.
Other
Everything else, worded as the crate worded it.
Implementations§
Source§impl DictateFailure
impl DictateFailure
Sourcepub fn is_cancelled(&self) -> bool
pub fn is_cancelled(&self) -> bool
true when the user stopped preflight rather than something
going wrong. The screen wording and forge’s exit differ.
Trait Implementations§
Source§impl Clone for DictateFailure
impl Clone for DictateFailure
Source§impl Debug for DictateFailure
impl Debug for DictateFailure
Source§impl<'de> Deserialize<'de> for DictateFailure
impl<'de> Deserialize<'de> for DictateFailure
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
impl Eq for DictateFailure
Source§impl PartialEq for DictateFailure
impl PartialEq for DictateFailure
Source§impl Serialize for DictateFailure
impl Serialize for DictateFailure
impl StructuralPartialEq for DictateFailure
Auto Trait Implementations§
impl Freeze for DictateFailure
impl RefUnwindSafe for DictateFailure
impl Send for DictateFailure
impl Sync for DictateFailure
impl Unpin for DictateFailure
impl UnsafeUnpin for DictateFailure
impl UnwindSafe for DictateFailure
Blanket Implementations§
§impl<T> AnySync for T
impl<T> AnySync for T
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
impl<S, T> Duplex<S> for Twhere
T: FromSample<S> + ToSample<S>,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.§impl<S> FromSample<S> for S
impl<S> FromSample<S> for S
fn from_sample_(s: S) -> S
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more