ESPHome 2026.11.0-dev
Loading...
Searching...
No Matches
haier_tundra_switch.h
Go to the documentation of this file.
1#pragma once
2
6
7namespace esphome::haier_tundra {
8
9enum class SwitchKind : uint8_t {
13};
14
15class HaierTundraSwitch final : public switch_::Switch, public Component, public Parented<HaierTundra> {
16 public:
17 HaierTundraSwitch(HaierTundra *parent, SwitchKind kind) : Parented(parent), kind_(kind) {}
18 void setup() override;
19 void dump_config() override;
20
21 protected:
22 void write_state(bool state) override;
23 void apply_(bool state, bool transmit);
24
26};
27
28} // namespace esphome::haier_tundra
Helper class to easily give an object a parent of type T.
Definition helpers.h:1997
HaierTundraSwitch(HaierTundra *parent, SwitchKind kind)
Base class for all switches.
Definition switch.h:38
bool state
The current reported state of the binary sensor.
Definition switch.h:55