pub struct ThermalDomain {
pub thermal_state: Option<ThermalState>,
pub components: Option<Vec<ThermalComponent>>,
pub ambient_temp_c: Option<f64>,
pub cooling_system: Option<CoolingSystem>,
pub heating_system: Option<HeatingSystem>,
pub is_throttling: Option<bool>,
}Expand description
Thermal domain containing temperature and cooling information.
Fields§
§thermal_state: Option<ThermalState>Overall thermal state
components: Option<Vec<ThermalComponent>>Component temperatures
ambient_temp_c: Option<f64>Ambient temperature (Celsius)
cooling_system: Option<CoolingSystem>Cooling system
heating_system: Option<HeatingSystem>Heating system
is_throttling: Option<bool>Whether thermal throttling active
Implementations§
Source§impl ThermalDomain
impl ThermalDomain
Sourcepub fn new(state: ThermalState) -> Self
pub fn new(state: ThermalState) -> Self
Create with thermal state.
Sourcepub fn with_component(self, component: ThermalComponent) -> Self
pub fn with_component(self, component: ThermalComponent) -> Self
Add component.
Sourcepub fn with_ambient(self, temp_c: f64) -> Self
pub fn with_ambient(self, temp_c: f64) -> Self
Set ambient temperature.
Sourcepub fn with_cooling(self, cooling: CoolingSystem) -> Self
pub fn with_cooling(self, cooling: CoolingSystem) -> Self
Add cooling system.
Trait Implementations§
Source§impl Clone for ThermalDomain
impl Clone for ThermalDomain
Source§fn clone(&self) -> ThermalDomain
fn clone(&self) -> ThermalDomain
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 ThermalDomain
impl Debug for ThermalDomain
Source§impl Default for ThermalDomain
impl Default for ThermalDomain
Source§fn default() -> ThermalDomain
fn default() -> ThermalDomain
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for ThermalDomain
impl<'de> Deserialize<'de> for ThermalDomain
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 ThermalDomain
impl RefUnwindSafe for ThermalDomain
impl Send for ThermalDomain
impl Sync for ThermalDomain
impl Unpin for ThermalDomain
impl UnwindSafe for ThermalDomain
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