42 bool check(
const Ts &...
x)
override {
62static_assert(
sizeof(LockStateForwarder<LockState::LOCK_STATE_LOCKED>) <=
sizeof(
void *));
63static_assert(std::is_trivially_copyable_v<LockStateForwarder<LockState::LOCK_STATE_LOCKED>>);
void trigger(const Ts &...x) ESPHOME_ALWAYS_INLINE
Base class for all automation conditions.
void play(const Ts &...x) override
LockCondition(Lock *parent, bool state)
bool check(const Ts &...x) override
Base class for all locks.
void lock()
Turn this lock on.
LockState state
The current reported state of the lock.
void unlock()
Turn this lock off.
void open()
Open (unlatch) this lock.
void play(const Ts &...x) override
void play(const Ts &...x) override
UnlockAction(Lock *a_lock)
LockState
Enum for all states a lock can be in.
Callback forwarder that triggers an Automation<> only when a specific lock state is entered.
void operator()(LockState state) const