mirror of
https://github.com/esphome/esphome.git
synced 2026-02-08 08:41:59 +00:00
make clang-tidy happy
This commit is contained in:
@@ -1035,7 +1035,7 @@ void APIConnection::try_send_camera_image_() {
|
||||
msg.device_id = camera::Camera::instance()->get_device_id();
|
||||
#endif
|
||||
|
||||
if (!this->send_message_impl(msg, CameraImageResponse::MESSAGE_TYPE)) {
|
||||
if (!this->send_message_impl_(msg, CameraImageResponse::MESSAGE_TYPE)) {
|
||||
return; // Send failed, try again later
|
||||
}
|
||||
this->image_reader_->consume_data(to_send);
|
||||
@@ -1443,7 +1443,7 @@ bool APIConnection::try_send_log_message(int level, const char *tag, const char
|
||||
SubscribeLogsResponse msg;
|
||||
msg.level = static_cast<enums::LogLevel>(level);
|
||||
msg.set_message(reinterpret_cast<const uint8_t *>(line), message_len);
|
||||
return this->send_message_impl(msg, SubscribeLogsResponse::MESSAGE_TYPE);
|
||||
return this->send_message_impl_(msg, SubscribeLogsResponse::MESSAGE_TYPE);
|
||||
}
|
||||
|
||||
void APIConnection::complete_authentication_() {
|
||||
@@ -1768,7 +1768,7 @@ bool APIConnection::try_to_clear_buffer(bool log_out_of_space) {
|
||||
}
|
||||
return false;
|
||||
}
|
||||
bool APIConnection::send_message_impl(const ProtoMessage &msg, uint8_t message_type) {
|
||||
bool APIConnection::send_message_impl_(const ProtoMessage &msg, uint8_t message_type) {
|
||||
ProtoSize size;
|
||||
msg.calculate_size(size);
|
||||
std::vector<uint8_t> &shared_buf = this->parent_->get_shared_buffer_ref();
|
||||
|
||||
@@ -255,7 +255,7 @@ class APIConnection final : public APIServerConnection {
|
||||
|
||||
void on_fatal_error() override;
|
||||
void on_no_setup_connection() override;
|
||||
bool send_message_impl(const ProtoMessage &msg, uint8_t message_type) override;
|
||||
bool send_message_impl_(const ProtoMessage &msg, uint8_t message_type) override;
|
||||
|
||||
void prepare_first_message_buffer(std::vector<uint8_t> &shared_buf, size_t header_padding, size_t total_size) {
|
||||
shared_buf.clear();
|
||||
|
||||
@@ -23,7 +23,7 @@ class APIServerConnectionBase : public ProtoService {
|
||||
DumpBuffer dump_buf;
|
||||
this->log_send_message_(msg.message_name(), msg.dump_to(dump_buf));
|
||||
#endif
|
||||
return this->send_message_impl(msg, message_type);
|
||||
return this->send_message_impl_(msg, message_type);
|
||||
}
|
||||
|
||||
virtual void on_hello_request(const HelloRequest &value){};
|
||||
|
||||
@@ -966,7 +966,7 @@ class ProtoService {
|
||||
* @param message_type The message type identifier.
|
||||
* @return True if the message was sent successfully, false otherwise.
|
||||
*/
|
||||
virtual bool send_message_impl(const ProtoMessage &msg, uint8_t message_type) = 0;
|
||||
virtual bool send_message_impl_(const ProtoMessage &msg, uint8_t message_type) = 0;
|
||||
|
||||
// Authentication helper methods
|
||||
inline bool check_connection_setup_() {
|
||||
|
||||
@@ -2848,7 +2848,7 @@ static const char *const TAG = "api.service";
|
||||
hpp += " DumpBuffer dump_buf;\n"
|
||||
hpp += " this->log_send_message_(msg.message_name(), msg.dump_to(dump_buf));\n"
|
||||
hpp += "#endif\n"
|
||||
hpp += " return this->send_message_impl(msg, message_type);\n"
|
||||
hpp += " return this->send_message_impl_(msg, message_type);\n"
|
||||
hpp += " }\n\n"
|
||||
|
||||
# Add logging helper method implementations to cpp
|
||||
|
||||
Reference in New Issue
Block a user