MCPcopy Create free account
hub / github.com/ElementsProject/elements / Put

Method Put

src/leveldb/db/write_batch.cc:98–103  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

96}
97
98void WriteBatch::Put(const Slice& key, const Slice& value) {
99 WriteBatchInternal::SetCount(this, WriteBatchInternal::Count(this) + 1);
100 rep_.push_back(static_cast<char>(kTypeValue));
101 PutLengthPrefixedSlice(&rep_, key);
102 PutLengthPrefixedSlice(&rep_, value);
103}
104
105void WriteBatch::Delete(const Slice& key) {
106 WriteBatchInternal::SetCount(this, WriteBatchInternal::Count(this) + 1);

Callers 1

IterateMethod · 0.45

Calls 2

PutLengthPrefixedSliceFunction · 0.85
push_backMethod · 0.45

Tested by

no test coverage detected