diff options
| author | Jan Tuomi <jan@jantuomi.fi> | 2024-11-29 15:18:17 +0200 |
|---|---|---|
| committer | Jan Tuomi <jan@jantuomi.fi> | 2024-11-29 15:18:17 +0200 |
| commit | 6caaac539308dd56b669c39c9665806e6ead6112 (patch) | |
| tree | 9cf5081e5eba792278fd89492bb900235393110d /log_db/src/memtable_primary.rs | |
| parent | 10dcde18ad2c02df9d0294d75cfa5ef01f53ada3 (diff) | |
Add tombstone flag to record to support delete
Diffstat (limited to 'log_db/src/memtable_primary.rs')
| -rw-r--r-- | log_db/src/memtable_primary.rs | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/log_db/src/memtable_primary.rs b/log_db/src/memtable_primary.rs index 6a28f30..85648d4 100644 --- a/log_db/src/memtable_primary.rs +++ b/log_db/src/memtable_primary.rs @@ -26,4 +26,8 @@ impl PrimaryMemtable { pub fn get(&self, key: &IndexableValue) -> Option<&LogKey> { self.records.get(key) } + + pub fn remove(&mut self, key: &IndexableValue) -> Option<LogKey> { + self.records.remove(key) + } } |
