| /leveldb-1.20/db/ |
| H A D | log_reader.cc | 60 bool Reader::ReadRecord(Slice* record, std::string* scratch) { in ReadRecord() argument 67 scratch->clear(); in ReadRecord() 102 if (scratch->empty()) { in ReadRecord() 109 scratch->clear(); in ReadRecord() 120 if (scratch->empty()) { in ReadRecord() 127 scratch->assign(fragment.data(), fragment.size()); in ReadRecord() 136 scratch->append(fragment.data(), fragment.size()); in ReadRecord() 146 *record = Slice(*scratch); in ReadRecord() 157 scratch->clear(); in ReadRecord() 165 scratch->clear(); in ReadRecord() [all …]
|
| H A D | memtable.cc | 44 static const char* EncodeKey(std::string* scratch, const Slice& target) { in EncodeKey() argument 45 scratch->clear(); in EncodeKey() 46 PutVarint32(scratch, target.size()); in EncodeKey() 47 scratch->append(target.data(), target.size()); in EncodeKey() 48 return scratch->data(); in EncodeKey()
|
| H A D | log_test.cc | 61 virtual Status Read(size_t n, Slice* result, char* scratch) { in Read() argument 146 std::string scratch; in Read() local 148 if (reader_->ReadRecord(&record, &scratch)) { in Read() 215 std::string scratch; in CheckOffsetPastEndReturnsNoRecords() local 216 ASSERT_TRUE(!offset_reader->ReadRecord(&record, &scratch)); in CheckOffsetPastEndReturnsNoRecords() 233 std::string scratch; in CheckInitialOffsetRecord() local 234 ASSERT_TRUE(offset_reader->ReadRecord(&record, &scratch)); in CheckInitialOffsetRecord()
|
| H A D | log_reader.h | 53 bool ReadRecord(Slice* record, std::string* scratch);
|
| H A D | dumpfile.cc | 62 std::string scratch; in PrintLogContents() local 63 while (reader.ReadRecord(&record, &scratch)) { in PrintLogContents()
|
| H A D | fault_injection_test.cc | 60 char* scratch = new char[length]; in Truncate() local 62 s = orig_file->Read(length, &result, scratch); in Truncate() 79 delete[] scratch; in Truncate()
|
| H A D | repair.cc | 197 std::string scratch; in ConvertLogToTable() local 203 while (reader.ReadRecord(&record, &scratch)) { in ConvertLogToTable()
|
| H A D | version_set.cc | 946 std::string scratch; in Recover() local 947 while (reader.ReadRecord(&record, &scratch) && s.ok()) { in Recover() 1138 const char* VersionSet::LevelSummary(LevelSummaryStorage* scratch) const { in LevelSummary() 1141 snprintf(scratch->buffer, sizeof(scratch->buffer), in LevelSummary() 1150 return scratch->buffer; in LevelSummary()
|
| H A D | version_set.h | 269 const char* LevelSummary(LevelSummaryStorage* scratch) const;
|
| H A D | db_impl.cc | 408 std::string scratch; in RecoverLogFile() local 413 while (reader.ReadRecord(&record, &scratch) && in RecoverLogFile()
|
| H A D | db_test.cc | 175 char* scratch) const { in NewRandomAccessFile() 177 return target_->Read(offset, n, result, scratch); in NewRandomAccessFile()
|
| /leveldb-1.20/helpers/memenv/ |
| H A D | memenv_test.cc | 101 char scratch[100]; in TEST() local 112 ASSERT_OK(seq_file->Read(5, &result, scratch)); // Read "hello". in TEST() 115 ASSERT_OK(seq_file->Read(1000, &result, scratch)); // Read "world". in TEST() 120 ASSERT_OK(seq_file->Read(1000, &result, scratch)); in TEST() 126 ASSERT_OK(rand_file->Read(6, 5, &result, scratch)); // Read "world". in TEST() 130 ASSERT_OK(rand_file->Read(10, 100, &result, scratch)); // Read "d". in TEST() 134 ASSERT_TRUE(!rand_file->Read(1000, 5, &result, scratch).ok()); in TEST() 163 char* scratch = new char[kWriteSize * 2]; in TEST() local 179 ASSERT_OK(seq_file->Read(3, &result, scratch)); // Read "foo". in TEST() 185 ASSERT_OK(seq_file->Read(kWriteSize - read, &result, scratch)); in TEST() [all …]
|
| H A D | memenv.cc | 52 Status Read(uint64_t offset, size_t n, Slice* result, char* scratch) const { in Read() 76 char* dst = scratch; in Read() 91 *result = Slice(scratch, n); in Read() 159 virtual Status Read(size_t n, Slice* result, char* scratch) { in Read() argument 160 Status s = file_->Read(pos_, n, result, scratch); in Read() 195 char* scratch) const { in Read() 196 return file_->Read(offset, n, result, scratch); in Read()
|
| /leveldb-1.20/util/ |
| H A D | env_posix_test.cc | 47 char scratch; in TEST() local 50 ASSERT_OK(files[i]->Read(i, 1, &read_result, &scratch)); in TEST()
|
| H A D | env_posix.cc | 102 virtual Status Read(size_t n, Slice* result, char* scratch) { in Read() argument 104 size_t r = fread_unlocked(scratch, 1, n, file_); in Read() 105 *result = Slice(scratch, r); in Read() 152 char* scratch) const { in Read() 162 ssize_t r = pread(fd, scratch, n, static_cast<off_t>(offset)); in Read() 163 *result = Slice(scratch, (r < 0) ? 0 : r); in Read() 198 char* scratch) const { in Read()
|
| /leveldb-1.20/include/leveldb/ |
| H A D | env.h | 183 virtual Status Read(size_t n, Slice* result, char* scratch) = 0; 216 char* scratch) const = 0;
|
| /leveldb-1.20/table/ |
| H A D | table_test.cc | 121 char* scratch) const { in Read() 128 memcpy(scratch, &contents_[offset], n); in Read() 129 *result = Slice(scratch, n); in Read()
|