Renamed JsonArray::removeAt() into remove()

This commit is contained in:
Benoit Blanchon
2017-04-12 21:07:30 +02:00
parent 8c6f64c111
commit f2ef338cb8
6 changed files with 21 additions and 5 deletions
+2
View File
@@ -89,6 +89,8 @@ class List {
protected:
JsonBuffer *_buffer;
private:
node_type *_firstNode;
};
}
+8 -1
View File
@@ -131,7 +131,7 @@ class JsonArray : public Internals::JsonPrintable<JsonArray>,
JsonObject &createNestedObject();
// Removes element at specified index.
void removeAt(size_t index) {
void remove(size_t index) {
remove(begin() += index);
}
using Internals::List<JsonVariant>::remove;
@@ -197,6 +197,13 @@ class JsonArray : public Internals::JsonPrintable<JsonArray>,
}
}
#if ARDUINOJSON_ENABLE_DEPRECATED
DEPRECATED("use remove() instead")
FORCE_INLINE void removeAt(size_t index) {
return remove(index);
}
#endif
private:
template <typename TValueRef>
bool set_impl(size_t index, TValueRef value) {