pub struct HardwareProfile {
pub identifiers: Vec<HardwareIdentifier>,
pub problems: Vec<ProfileProblem>,
}Expand description
All identifiers found on this machine, plus why others are missing.
Fields§
§identifiers: Vec<HardwareIdentifier>§problems: Vec<ProfileProblem>Implementations§
Source§impl HardwareProfile
impl HardwareProfile
Sourcepub fn collect(sources: &HardwareSources) -> Self
pub fn collect(sources: &HardwareSources) -> Self
Collect the profile of this machine.
Sourcepub fn collect_explicit(
sources: &[ExplicitSource],
proc_root: Option<&Path>,
) -> Self
pub fn collect_explicit( sources: &[ExplicitSource], proc_root: Option<&Path>, ) -> Self
Collect from named sources only: each file’s first non-empty line is the
value. Nothing else of the host is read except /proc/cpuinfo (under
proc_root, if given), which is not namespaced. An empty list reports
ProfileProblem::NoSourceConfigured.
Sourcepub fn digest(&self) -> String
pub fn digest(&self) -> String
Stable digest over all identifier hashes (recorded with a trial).
Sourcepub fn bindings_for(&self, hashes: &[String]) -> Vec<Binding>
pub fn bindings_for(&self, hashes: &[String]) -> Vec<Binding>
Bindings of the identifiers with the given hashes (operator selection).
Trait Implementations§
Source§impl Clone for HardwareProfile
impl Clone for HardwareProfile
Source§fn clone(&self) -> HardwareProfile
fn clone(&self) -> HardwareProfile
Returns a copy 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 HardwareProfile
impl Debug for HardwareProfile
Source§impl Default for HardwareProfile
impl Default for HardwareProfile
Source§fn default() -> HardwareProfile
fn default() -> HardwareProfile
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for HardwareProfile
impl<'de> Deserialize<'de> for HardwareProfile
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
Source§impl PartialEq for HardwareProfile
impl PartialEq for HardwareProfile
Source§impl Serialize for HardwareProfile
impl Serialize for HardwareProfile
impl Eq for HardwareProfile
impl StructuralPartialEq for HardwareProfile
Auto Trait Implementations§
impl Freeze for HardwareProfile
impl RefUnwindSafe for HardwareProfile
impl Send for HardwareProfile
impl Sync for HardwareProfile
impl Unpin for HardwareProfile
impl UnwindSafe for HardwareProfile
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