Message

Struct Message 

Source
pub struct Message { /* private fields */ }

Implementations§

Source§

impl Message

Source

pub fn new() -> Self

Source

pub fn raw(&self) -> &[u8; 8]

Source

pub fn encode(&self) -> impl Iterator<Item = Code> + '_

Source

pub fn decode(codes: &[Code; 70]) -> Result<Self, DecodeError>

Source

pub fn mode(&self) -> Result<Mode, DecodeError>

Source

pub fn set_mode(&mut self, mode: Mode)

Source

pub fn is_on(&self) -> bool

Source

pub fn set_on(&mut self, on: bool)

Source

pub fn fan(&self) -> Fan

Source

pub fn set_fan(&mut self, fan: Fan)

Source

pub fn swing(&self) -> bool

Source

pub fn set_swing(&mut self, swing: bool)

Source

pub fn sleep(&self) -> bool

Source

pub fn set_sleep(&mut self, sleep: bool)

Source

pub fn temperature(&self) -> Result<Temperature, DecodeError>

Source

pub fn set_temperature(&mut self, temp: Temperature)

Source

pub fn timer(&self) -> Result<TimerSetting, DecodeError>

Source

pub fn set_timer(&mut self, setting: &TimerSetting)

Source

pub fn turbo(&self) -> bool

Source

pub fn set_turbo(&mut self, turbo: bool)

Source

pub fn light(&self) -> bool

Source

pub fn set_light(&mut self, light: bool)

Source

pub fn health(&self) -> bool

Source

pub fn set_health(&mut self, health: bool)

Source

pub fn dry(&self) -> bool

Source

pub fn set_dry(&mut self, dry: bool)

Source

pub fn ventilate(&self) -> bool

Source

pub fn set_ventilateo(&mut self, ventilate: bool)

Source

pub fn v_swing(&self) -> SwingMode

Source

pub fn set_v_swing(&mut self, mode: SwingMode)

Source

pub fn h_swing(&self) -> SwingMode

Source

pub fn set_h_swing(&mut self, mode: SwingMode)

Source

pub fn temperature_display(&self) -> TemperatureDisplay

Source

pub fn set_temperature_display(&mut self, temp_display: TemperatureDisplay)

Source

pub fn i_feel(&self) -> bool

Source

pub fn set_i_feel(&mut self, i_feel: bool)

Source

pub fn wifi(&self) -> bool

Source

pub fn set_wifi(&mut self, wifi: bool)

Source

pub fn econo(&self) -> bool

Source

pub fn set_econo(&mut self, econo: bool)

Trait Implementations§

Source§

impl Clone for Message

Source§

fn clone(&self) -> Message

Returns a duplicate of the value. Read more
1.0.0§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for Message

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

Blanket Implementations§

§

impl<T> Any for T
where T: 'static + ?Sized,

§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
§

impl<T> Borrow<T> for T
where T: ?Sized,

§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
§

impl<T> BorrowMut<T> for T
where T: ?Sized,

§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
§

impl<T> CloneToUninit for T
where T: Clone,

§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
§

impl<T> From<T> for T

§

fn from(t: T) -> T

Returns the argument unchanged.

§

impl<T, U> Into<U> for T
where U: From<T>,

§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.