#include "leveldb/write_batch.h"
#include "db/dbformat.h"
#include "db/memtable.h"
#include "db/write_batch_internal.h"
#include "leveldb/db.h"
#include "util/coding.h"
namespace leveldb {
static const size_t kHeader = …;
WriteBatch::WriteBatch() { … }
WriteBatch::~WriteBatch() = default;
WriteBatch::Handler::~Handler() = default;
void WriteBatch::Clear() { … }
size_t WriteBatch::ApproximateSize() const { … }
Status WriteBatch::Iterate(Handler* handler) const { … }
int WriteBatchInternal::Count(const WriteBatch* b) { … }
void WriteBatchInternal::SetCount(WriteBatch* b, int n) { … }
SequenceNumber WriteBatchInternal::Sequence(const WriteBatch* b) { … }
void WriteBatchInternal::SetSequence(WriteBatch* b, SequenceNumber seq) { … }
void WriteBatch::Put(const Slice& key, const Slice& value) { … }
void WriteBatch::Delete(const Slice& key) { … }
void WriteBatch::Append(const WriteBatch& source) { … }
namespace {
class MemTableInserter : public WriteBatch::Handler { … };
}
Status WriteBatchInternal::InsertInto(const WriteBatch* b, MemTable* memtable) { … }
void WriteBatchInternal::SetContents(WriteBatch* b, const Slice& contents) { … }
void WriteBatchInternal::Append(WriteBatch* dst, const WriteBatch* src) { … }
}