mirror of
https://github.com/eledio-devices/thirdparty-ArduinoJson.git
synced 2025-11-01 16:14:05 +01:00
33 lines
639 B
C++
33 lines
639 B
C++
// Copyright Benoit Blanchon 2014
|
|
// MIT License
|
|
//
|
|
// Arduino JSON library
|
|
// https://github.com/bblanchon/ArduinoJson
|
|
|
|
#pragma once
|
|
|
|
#include "JsonNode.hpp"
|
|
|
|
namespace ArduinoJson {
|
|
namespace Internals {
|
|
// TODO: replace by JsonArrayIterator and JsonObjectIterator
|
|
class JsonNodeIterator {
|
|
public:
|
|
explicit JsonNodeIterator(JsonNode *node) : _node(node) {}
|
|
|
|
bool operator!=(const JsonNodeIterator &other) const {
|
|
return _node != other._node;
|
|
}
|
|
|
|
void operator++() { _node = _node->next; }
|
|
|
|
JsonNode *operator*() const { return _node; }
|
|
|
|
JsonNode *operator->() const { return _node; }
|
|
|
|
private:
|
|
JsonNode *_node;
|
|
};
|
|
}
|
|
}
|