pub struct UpdateResult {
pub succeeded: Vec<String>,
pub failed: Vec<FailedUpdate>,
pub skipped: Vec<String>,
pub unverified: Vec<UnverifiedUpdate>,
}Expand description
Result of performing updates.
Returned by update(). Tracks which components succeeded,
failed, or were skipped during the update run.
Fields§
§succeeded: Vec<String>§failed: Vec<FailedUpdate>§skipped: Vec<String>§unverified: Vec<UnverifiedUpdate>Components that installed successfully but whose post-install version could not be verified to match the expected version.
Implementations§
Source§impl UpdateResult
impl UpdateResult
Sourcepub fn has_failures(&self) -> bool
pub fn has_failures(&self) -> bool
Returns true if any component failed to update.
Sourcepub fn success_count(&self) -> usize
pub fn success_count(&self) -> usize
Returns the number of successfully updated components.
Sourcepub fn failure_count(&self) -> usize
pub fn failure_count(&self) -> usize
Returns the number of components that failed to update.
Sourcepub fn print_error_table(&self)
pub fn print_error_table(&self)
Prints a formatted table of failed updates to stdout.
Sourcepub fn print_summary(&self)
pub fn print_summary(&self)
Prints a one-line summary of the update outcome to stdout.
Trait Implementations§
Source§impl Clone for UpdateResult
impl Clone for UpdateResult
Source§fn clone(&self) -> UpdateResult
fn clone(&self) -> UpdateResult
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for UpdateResult
impl Debug for UpdateResult
Source§impl Default for UpdateResult
impl Default for UpdateResult
Source§fn default() -> UpdateResult
fn default() -> UpdateResult
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for UpdateResult
impl RefUnwindSafe for UpdateResult
impl Send for UpdateResult
impl Sync for UpdateResult
impl Unpin for UpdateResult
impl UnsafeUnpin for UpdateResult
impl UnwindSafe for UpdateResult
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> 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>
Converts
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>
Converts
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