pub struct CpuInfo {
pub usage_pct: Option<f64>,
pub per_core_pct: Option<Vec<f64>>,
pub core_count: Option<u32>,
pub temperature_c: Option<f64>,
pub frequency_mhz: Option<f64>,
pub model: Option<String>,
pub user_pct: Option<f64>,
pub system_pct: Option<f64>,
pub idle_pct: Option<f64>,
pub iowait_pct: Option<f64>,
pub is_throttling: Option<bool>,
}Expand description
CPU information.
Fields§
§usage_pct: Option<f64>CPU usage percentage (0-100)
per_core_pct: Option<Vec<f64>>Per-core usage percentages
core_count: Option<u32>Number of cores
temperature_c: Option<f64>CPU temperature in Celsius
frequency_mhz: Option<f64>CPU frequency in MHz
model: Option<String>CPU model name
user_pct: Option<f64>User time percentage
system_pct: Option<f64>System time percentage
idle_pct: Option<f64>Idle time percentage
iowait_pct: Option<f64>IO wait percentage
is_throttling: Option<bool>Whether CPU is throttling
Implementations§
Trait Implementations§
Source§impl<'de> Deserialize<'de> for CpuInfo
impl<'de> Deserialize<'de> for CpuInfo
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 CpuInfo
impl RefUnwindSafe for CpuInfo
impl Send for CpuInfo
impl Sync for CpuInfo
impl Unpin for CpuInfo
impl UnwindSafe for CpuInfo
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