Struct thermostat::Thermostat [−][src]
pub struct Thermostat<'a> { /* fields omitted */ }
Thermostat state machine
Methods
impl<'a> Thermostat<'a>
[src]
impl<'a> Thermostat<'a>
pub fn new(interface: &ThermostatInterface) -> Thermostat
[src]
pub fn new(interface: &ThermostatInterface) -> Thermostat
Create a new thermostat using the provided interface
pub fn set_operating_mode(
&mut self,
operating_mode: OperatingMode
) -> Result<(), Error>
[src]
pub fn set_operating_mode(
&mut self,
operating_mode: OperatingMode
) -> Result<(), Error>
Change the current operating mode.
Will return an Err result if the specified operating mode is incompatible with the current configuration.
pub fn get_operating_mode(&self) -> OperatingMode
[src]
pub fn get_operating_mode(&self) -> OperatingMode
Get the current operating mode.
pub fn set_maximum_safe_temperature(
&mut self,
temperature: f64
) -> Result<(), Error>
[src]
pub fn set_maximum_safe_temperature(
&mut self,
temperature: f64
) -> Result<(), Error>
Change the minimum safe temperature.
If the maximum set temperature is higher than the specified maximum safe temperature, the maximum set temperature will be automatically adjusted to match.
An Err Result is returned if the specified temperature is not within the bounds of the minimum and maximum safe temperatures.
pub fn get_maximum_safe_temperature(&self) -> f64
[src]
pub fn get_maximum_safe_temperature(&self) -> f64
Get the current maximum safe temperature.
pub fn set_minimum_safe_temperature(
&mut self,
temperature: f64
) -> Result<(), Error>
[src]
pub fn set_minimum_safe_temperature(
&mut self,
temperature: f64
) -> Result<(), Error>
Change the minimum safe temperature.
If the minimum set temperature is lower than the specified minimum safe temperature, the minimum set temperature will be automatically adjusted to match.
An Err Result is returned if the specified temperature is not within the bounds of the minimum and maximum safe temperatures.
pub fn get_minimum_safe_temperature(&self) -> f64
[src]
pub fn get_minimum_safe_temperature(&self) -> f64
Get the current minimum safe temperature
pub fn set_maximum_set_temperature(
&mut self,
temperature: f64
) -> Result<(), Error>
[src]
pub fn set_maximum_set_temperature(
&mut self,
temperature: f64
) -> Result<(), Error>
Change the maximum set temperature.
If the minimum set temperature is higher than the specified maximum set temperature, the minimum set temperature will be automatically adjusted to match.
An Err Result is returned if the specified temperature is not within the bounds of the minimum and maximum safe temperatures.
pub fn get_maximum_set_temperature(&self) -> f64
[src]
pub fn get_maximum_set_temperature(&self) -> f64
Get the current maximum set temperature.
pub fn set_minimum_set_temperature(
&mut self,
temperature: f64
) -> Result<(), Error>
[src]
pub fn set_minimum_set_temperature(
&mut self,
temperature: f64
) -> Result<(), Error>
Change the minimum set temperature.
If the minimum set temperature is higher than the specified maximum set temperature, the maximum set temperature will be automatically adjusted to match.
An Err Result is returned if the specified temperature is not within the bounds of the minimum and maximum safe temperatures.
pub fn get_minimum_set_temperature(&self) -> f64
[src]
pub fn get_minimum_set_temperature(&self) -> f64
Get the current minimum set temperature.
pub fn get_current_temperature(&self) -> f64
[src]
pub fn get_current_temperature(&self) -> f64
Get the current temperature as known to the thermostat
pub fn set_current_temperature(&mut self, temperature: f64) -> Result<(), Error>
[src]
pub fn set_current_temperature(&mut self, temperature: f64) -> Result<(), Error>
Update the thermostat with a new temperature reading
Trait Implementations
impl<'a> Copy for Thermostat<'a>
[src]
impl<'a> Copy for Thermostat<'a>
impl<'a> Clone for Thermostat<'a>
[src]
impl<'a> Clone for Thermostat<'a>
fn clone(&self) -> Thermostat<'a>
[src]
fn clone(&self) -> Thermostat<'a>
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
Auto Trait Implementations
impl<'a> !Send for Thermostat<'a>
impl<'a> !Send for Thermostat<'a>
impl<'a> !Sync for Thermostat<'a>
impl<'a> !Sync for Thermostat<'a>