esphome-ratgdo/components/ratgdo/ratgdo_child.h

32 lines
907 B
C
Raw Normal View History

2023-06-07 14:49:24 +00:00
#pragma once
#include "esphome/core/helpers.h"
2023-06-07 14:59:09 +00:00
#include "ratgdo.h"
2023-06-07 15:06:51 +00:00
#include "ratgdo_state.h"
2023-06-07 14:49:24 +00:00
namespace esphome {
namespace ratgdo {
2023-06-07 14:51:22 +00:00
// Forward declare RATGDOComponent
class RATGDOComponent;
2023-06-07 15:02:53 +00:00
2023-06-07 14:51:22 +00:00
class RATGDOClient : public Parented<RATGDOComponent> {
public:
2023-06-07 22:51:44 +00:00
virtual void on_door_state(DoorState state);
virtual void on_light_state(LightState state);
virtual void on_lock_state(LockState state);
virtual void on_motion_state(MotionState state);
virtual void on_obstruction_state(ObstructionState state);
2023-06-08 02:40:07 +00:00
virtual void on_motor_state(MotorState state);
2023-06-07 22:59:08 +00:00
virtual void on_rolling_code_change(uint32_t rollingCodeCounter);
2023-06-09 22:36:56 +00:00
virtual void on_openings_change(uint32_t openings);
2023-06-09 23:07:11 +00:00
virtual void on_button_state(ButtonState state);
2023-06-07 14:49:24 +00:00
2023-06-07 14:51:22 +00:00
protected:
friend RATGDOComponent;
};
2023-06-07 14:49:24 +00:00
2023-06-07 14:51:22 +00:00
} // namespace ratgdo
} // namespace esphome