esphome-api-client 0.5.0
Modern C++17 client for the ESPHome native API (plaintext + Noise)
Loading...
Searching...
No Matches
Public Member Functions | Static Public Member Functions | List of all members
esphome::api::LockEntity Class Reference

Handle to a Lock entity. More...

#include <entity_handles.hpp>

Inheritance diagram for esphome::api::LockEntity:
Inheritance graph
[legend]
Collaboration diagram for esphome::api::LockEntity:
Collaboration graph
[legend]

Public Member Functions

std::optional< LockInfoinfo () const
 
std::optional< LockEntityStatestate () const
 
bool assumed_state () const
 
bool supports_open () const
 
bool requires_code () const
 
std::string code_format () const
 
void command (LockCommandData c) const
 Send a fully-specified command (its key is set automatically).
 
void lock () const
 
void unlock () const
 
void open () const
 
- Public Member Functions inherited from esphome::api::TypedEntity< LockEntity >
std::string icon () const
 
bool disabled_by_default () const
 
EntityCategory entity_category () const
 
std::uint32_t device_id () const
 
 Entity (Client &client, const std::uint32_t key, std::string object_id, std::string name)
 
- Public Member Functions inherited from esphome::api::Entity
 Entity (Client &client, const std::uint32_t key, std::string object_id, std::string name)
 
std::uint32_t key () const noexcept
 
const std::string & object_id () const noexcept
 
const std::string & name () const noexcept
 

Static Public Member Functions

static constexpr EntityType type ()
 

Additional Inherited Members

- Protected Attributes inherited from esphome::api::Entity
Clientclient_
 
std::uint32_t key_
 
std::string object_id_
 
std::string name_
 

Detailed Description

Handle to a Lock entity.

Member Function Documentation

◆ assumed_state()

bool esphome::api::LockEntity::assumed_state ( ) const
inline

◆ code_format()

std::string esphome::api::LockEntity::code_format ( ) const
inline

◆ command()

void esphome::api::LockEntity::command ( LockCommandData  c) const
inline

Send a fully-specified command (its key is set automatically).

◆ info()

std::optional< LockInfo > esphome::api::LockEntity::info ( ) const
inline

◆ lock()

void esphome::api::LockEntity::lock ( ) const
inline

◆ open()

void esphome::api::LockEntity::open ( ) const
inline

◆ requires_code()

bool esphome::api::LockEntity::requires_code ( ) const
inline

◆ state()

std::optional< LockEntityState > esphome::api::LockEntity::state ( ) const
inline

◆ supports_open()

bool esphome::api::LockEntity::supports_open ( ) const
inline

◆ type()

static constexpr EntityType esphome::api::LockEntity::type ( )
inlinestaticconstexpr

◆ unlock()

void esphome::api::LockEntity::unlock ( ) const
inline

The documentation for this class was generated from the following file: