pub struct BatteryInfo {
pub battery_powered: bool,
pub charging: bool,
pub ac_present: bool,
pub health_ok: bool,
pub temperature_max: Celsius,
pub temperature_1: Celsius,
pub temperature_2: Celsius,
}
Expand description
Various information about the battery in general.
Fields§
§battery_powered: bool
true
if the system is running on battery power
charging: bool
true
if the battery is currently being charged
ac_present: bool
true
if the system is plugged in
health_ok: bool
true
if the battery health is generally ok
temperature_max: Celsius
The highest measured temperature sensor
temperature_1: Celsius
The temperature of the first battery sensor
temperature_2: Celsius
The temperature of the second battery sensor
Trait Implementations§
Source§impl Clone for BatteryInfo
impl Clone for BatteryInfo
Source§fn clone(&self) -> BatteryInfo
fn clone(&self) -> BatteryInfo
Returns a duplicate 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 BatteryInfo
impl Debug for BatteryInfo
Source§impl PartialEq for BatteryInfo
impl PartialEq for BatteryInfo
impl Copy for BatteryInfo
impl StructuralPartialEq for BatteryInfo
Auto Trait Implementations§
impl Freeze for BatteryInfo
impl RefUnwindSafe for BatteryInfo
impl Send for BatteryInfo
impl Sync for BatteryInfo
impl Unpin for BatteryInfo
impl UnwindSafe for BatteryInfo
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