Add documentation to most public symbols

This commit is contained in:
Benoit Blanchon
2022-12-19 15:37:41 +01:00
parent 2a32803e9e
commit de725e0a4e
23 changed files with 497 additions and 140 deletions

View File

@@ -8,6 +8,7 @@
namespace ARDUINOJSON_NAMESPACE {
// A JsonDocument with a memory pool on the stack.
template <size_t desiredCapacity>
class StaticJsonDocument : public JsonDocument {
static const size_t _capacity =
@@ -45,6 +46,8 @@ class StaticJsonDocument : public JsonDocument {
return *this;
}
// Reclaims the memory leaked when removing and replacing values.
// https://arduinojson.org/v6/api/jsondocument/garbagecollect/
void garbageCollect() {
StaticJsonDocument tmp(*this);
set(tmp);