pub struct DeferredUpdate {
pub current_version: String,
pub latest_version: String,
pub update_available: bool,
pub channel: UpgradeChannel,
pub install_method: InstallMethod,
pub update_command: String,
}Expand description
Outcome of an update declined because a package manager owns this installation.
Reported instead of UpdateResult when ant was installed by a package manager: the
version check still runs, so the caller learns whether an update exists, but the binary is
left alone and update_command says how to get it.
Fields§
§current_version: String§latest_version: String§update_available: bool§channel: UpgradeChannel§install_method: InstallMethodHow this copy of ant was installed.
update_command: StringThe command that will perform the update.
Implementations§
Source§impl DeferredUpdate
impl DeferredUpdate
Sourcepub fn new(check: &UpdateCheck, method: InstallMethod) -> Option<Self>
pub fn new(check: &UpdateCheck, method: InstallMethod) -> Option<Self>
Build the deferral report for check under method.
Returns None for an install ant update may replace itself.
Trait Implementations§
Source§impl Clone for DeferredUpdate
impl Clone for DeferredUpdate
Source§impl Debug for DeferredUpdate
impl Debug for DeferredUpdate
Source§impl<'de> Deserialize<'de> for DeferredUpdate
impl<'de> Deserialize<'de> for DeferredUpdate
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>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for DeferredUpdate
impl RefUnwindSafe for DeferredUpdate
impl Send for DeferredUpdate
impl Sync for DeferredUpdate
impl Unpin for DeferredUpdate
impl UnsafeUnpin for DeferredUpdate
impl UnwindSafe for DeferredUpdate
Blanket Implementations§
impl<T> AdapterBounds for Twhere
T: Sync,
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
impl<'de, T> BorrowedRpcObject<'de> for 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>,
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