#[repr(C)]pub enum UpdateMode {
SelfUpdate = 0,
NotifyOnly = 1,
Disabled = 2,
}Expand description
Requested update behaviour.
The EFFECTIVE behaviour is this clamped by what the installation permits:
a package-managed binary (dpkg-owned, /usr, snap, flatpak,
WindowsApps) NEVER self-updates — SelfUpdate degrades to
NotifyOnly there (“update via your package manager”).
Variants§
SelfUpdate = 0
Check, notify, and — after the user consents — download and swap the binary. Staging may happen in the background; INSTALLING never does.
NotifyOnly = 1
Check and notify only (“new version available”); installing is the user’s / packager’s job. The mode packagers should ship.
Disabled = 2
Never check for updates.
Trait Implementations§
Source§impl Clone for UpdateMode
impl Clone for UpdateMode
Source§fn clone(&self) -> UpdateMode
fn clone(&self) -> UpdateMode
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for UpdateMode
Source§impl Debug for UpdateMode
impl Debug for UpdateMode
Source§impl Default for UpdateMode
impl Default for UpdateMode
Source§fn default() -> UpdateMode
fn default() -> UpdateMode
Returns the “default value” for a type. Read more
impl Eq for UpdateMode
Source§impl Hash for UpdateMode
impl Hash for UpdateMode
Source§impl Ord for UpdateMode
impl Ord for UpdateMode
Source§fn cmp(&self, other: &UpdateMode) -> Ordering
fn cmp(&self, other: &UpdateMode) -> Ordering
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
1.21.0 (const: unstable) · Source§fn min(self, other: Self) -> Selfwhere
Self: Sized,
fn min(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the minimum of two values. Read more
Source§impl PartialEq for UpdateMode
impl PartialEq for UpdateMode
Source§impl PartialOrd for UpdateMode
impl PartialOrd for UpdateMode
impl StructuralPartialEq for UpdateMode
Auto Trait Implementations§
impl Freeze for UpdateMode
impl RefUnwindSafe for UpdateMode
impl Send for UpdateMode
impl Sync for UpdateMode
impl Unpin for UpdateMode
impl UnsafeUnpin for UpdateMode
impl UnwindSafe for UpdateMode
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