func (db *DB) Remove(key []byte) error {
	db.writeLock.Lock()
	defer db.writeLock.Unlock()

	seqNumber := db.getSeqNumber()
	info := db.table.MarkDeleted(key, seqNumber)
	if info == nil {
		return nil
	}

	db.markPreviousAsStale(info.ptr.FileId, recordSize(len(key), int(info.ptr.valueSize)))
	_, err := db.writeRecordToFile(&Record{Key: key, Value: nil, SeqNumber: seqNumber})
	return err
}
// Remove removes the mapping for a key from the map if it is present.
Remove removes the mapping for a key from the map if it is present.
// Remove removes the mapping for a key from the map if it is present .
func (db *DB) Remove(key []byte) error {
	db.writeLock.Lock()
	defer db.writeLock.Unlock()
	seqNumber := db.getSeqNumber()
	info := db.table.MarkDeleted(key, seqNumber)
	if info == nil {
		return nil
	}
	db.markPreviousAsStale(info.ptr.FileId, recordSize(len(key), int(info.ptr.valueSize)))
	_, err := db.writeRecordToFile(&Record{Key: key, Value: nil, SeqNumber: seqNumber})
	return err
}
func ( db * DB ) Remove ( key [ ] byte ) error { db . writeLock . Lock ( ) defer db . writeLock . Unlock ( ) seqNumber := db . getSeqNumber ( ) info := db . table . MarkDeleted ( key , seqNumber ) if info == nil { return nil } db . markPreviousAsStale ( info . ptr . FileId , recordSize ( len ( key ) , int ( info . ptr . valueSize ) ) ) _ , err := db . writeRecordToFile ( & Record { Key : key , Value : nil , SeqNumber : seqNumber } ) return err }
Remove removes the mapping for a key from the map if it is present.
Remove removes the mapping for a key from the map if it is present .