JsonVariant::remove()
Description
Depending on the type of its argument, JsonVariant::remove() either:
- removes the element at the specified index from the array pointed by the
JsonVariant - removes the member with the specified key in the object pointed by the
JsonVariant
In other words, JsonVariant::remove() behaves like JsonArray::remove() or JsonObject::remove().
Signature
void remove(size_t index) const;
void remove(const char* key) const;
void remove(const __FlashStringHelper* key) const;
void remove(const String& key) const;
void remove(const std::string& key) const;
void remove(std::string_view key) const;
Arguments
index: the zero-based position of the array element to remove.
key: the key of the object member to remove