MCPcopy Create free account
hub / github.com/couchbase/fleece / clear

Method clear

Fleece/Integration/MArray.hh:127–135  ·  view source on GitHub ↗

Removes all items from the array. */

Source from the content-addressed store, hash-verified

125
126 /** Removes all items from the array. */
127 bool clear() {
128 if (_usuallyFalse(!MCollection::isMutable()))
129 return false;
130 if (_vec.empty())
131 return true;
132 MCollection::mutate();
133 _vec.clear();
134 return true;
135 }
136
137 /** Writes the array to an Encoder as a single Value. */
138 void encodeTo(Encoder &enc) const {

Callers

nothing calls this directly

Calls 1

emptyMethod · 0.45

Tested by

no test coverage detected