ESPHome 2026.3.0-dev
Loading...
Searching...
No Matches
esphome::api::ProtoService Class Referenceabstract

#include <proto.h>

Inheritance diagram for esphome::api::ProtoService:
esphome::api::APIServerConnectionBase esphome::api::APIConnection

Protected Member Functions

virtual bool is_authenticated ()=0
 
virtual bool is_connection_setup ()=0
 
virtual void on_fatal_error ()=0
 
virtual void on_no_setup_connection ()=0
 
virtual bool send_buffer (ProtoWriteBuffer buffer, uint8_t message_type)=0
 
virtual void read_message (uint32_t msg_size, uint32_t msg_type, const uint8_t *msg_data)=0
 
virtual bool send_message_impl (const ProtoMessage &msg, uint8_t message_type)=0
 Send a protobuf message by calculating its size, allocating a buffer, encoding, and sending.
 
bool check_connection_setup_ ()
 
bool check_authenticated_ ()
 

Detailed Description

Definition at line 987 of file proto.h.

Member Function Documentation

◆ check_authenticated_()

bool esphome::api::ProtoService::check_authenticated_ ( )
inlineprotected

Definition at line 1014 of file proto.h.

◆ check_connection_setup_()

bool esphome::api::ProtoService::check_connection_setup_ ( )
inlineprotected

Definition at line 1006 of file proto.h.

◆ is_authenticated()

virtual bool esphome::api::ProtoService::is_authenticated ( )
protectedpure virtual

Implemented in esphome::api::APIConnection.

◆ is_connection_setup()

virtual bool esphome::api::ProtoService::is_connection_setup ( )
protectedpure virtual

Implemented in esphome::api::APIConnection.

◆ on_fatal_error()

virtual void esphome::api::ProtoService::on_fatal_error ( )
protectedpure virtual

Implemented in esphome::api::APIConnection.

◆ on_no_setup_connection()

virtual void esphome::api::ProtoService::on_no_setup_connection ( )
protectedpure virtual

Implemented in esphome::api::APIConnection.

◆ read_message()

virtual void esphome::api::ProtoService::read_message ( uint32_t msg_size,
uint32_t msg_type,
const uint8_t * msg_data )
protectedpure virtual

◆ send_buffer()

virtual bool esphome::api::ProtoService::send_buffer ( ProtoWriteBuffer buffer,
uint8_t message_type )
protectedpure virtual

Implemented in esphome::api::APIConnection.

◆ send_message_impl()

virtual bool esphome::api::ProtoService::send_message_impl ( const ProtoMessage & msg,
uint8_t message_type )
protectedpure virtual

Send a protobuf message by calculating its size, allocating a buffer, encoding, and sending.

This is the implementation method - callers should use send_message() which adds logging.

Parameters
msgThe protobuf message to send.
message_typeThe message type identifier.
Returns
True if the message was sent successfully, false otherwise.

Implemented in esphome::api::APIConnection.


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