This commit is contained in:
Tomasz Duda 2024-09-30 23:02:24 +02:00
parent 86b2633b95
commit b088806229
5 changed files with 10 additions and 0 deletions

View file

@ -7,6 +7,8 @@
namespace esphome {
namespace api {
using namespace component_iterator;
class APIConnection;
class ListEntitiesIterator : public ComponentIterator {

View file

@ -8,6 +8,8 @@
namespace esphome {
namespace api {
using namespace component_iterator;
class APIConnection;
class InitialStateIterator : public ComponentIterator {

View file

@ -8,6 +8,7 @@
#endif
namespace esphome {
namespace component_iterator {
void ComponentIterator::begin(bool include_internal) {
this->state_ = IteratorState::BEGIN;
@ -392,4 +393,5 @@ bool ComponentIterator::on_camera(esp32_camera::ESP32Camera *camera) { return tr
#ifdef USE_MEDIA_PLAYER
bool ComponentIterator::on_media_player(media_player::MediaPlayer *media_player) { return true; }
#endif
} // namespace component_iterator
} // namespace esphome

View file

@ -16,6 +16,8 @@ class UserServiceDescriptor;
} // namespace api
#endif
namespace component_iterator {
class ComponentIterator {
public:
void begin(bool include_internal = false);
@ -171,4 +173,5 @@ class ComponentIterator {
bool include_internal_{false};
};
} // namespace component_iterator
} // namespace esphome

View file

@ -7,6 +7,7 @@
namespace esphome {
namespace web_server {
using namespace component_iterator;
class WebServer;
class ListEntitiesIterator : public ComponentIterator {