| 115 | } |
| 116 | |
| 117 | void clear(Allocator* allocator) { |
| 118 | for (PoolCount i = 0; i < count_; i++) |
| 119 | pools_[i].destroy(allocator); |
| 120 | count_ = 0; |
| 121 | freeList_ = NULL_SLOT; |
| 122 | if (pools_ != preallocatedPools_) { |
| 123 | allocator->deallocate(pools_); |
| 124 | pools_ = preallocatedPools_; |
| 125 | capacity_ = ARDUINOJSON_INITIAL_POOL_COUNT; |
| 126 | } |
| 127 | } |
| 128 | |
| 129 | SlotCount usage() const { |
| 130 | SlotCount total = 0; |
nothing calls this directly
no test coverage detected