#[non_exhaustive]pub enum Source {
OsRelease,
UsrLibOsRelease,
LegacyRelease,
Sysctl,
Registry,
SystemProperty,
Fallback,
}Expand description
Where a fact came from.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
OsRelease
/etc/os-release.
UsrLibOsRelease
/usr/lib/os-release.
LegacyRelease
A legacy release file (/etc/redhat-release, /etc/lsb-release, …).
Sysctl
A sysctl value (macOS, iOS).
Registry
The Windows registry or RtlGetVersion.
SystemProperty
An Android system property.
Fallback
None of the above: the answer names the OS family only.
Trait Implementations§
impl Copy for Source
impl Eq for Source
impl StructuralPartialEq for Source
Auto Trait Implementations§
impl Freeze for Source
impl RefUnwindSafe for Source
impl Send for Source
impl Sync for Source
impl Unpin for Source
impl UnsafeUnpin for Source
impl UnwindSafe for Source
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