|
|
@ -258,9 +258,10 @@ class DB { |
|
|
|
// This check is potentially lighter-weight than invoking DB::Get(). One way
|
|
|
|
// This check is potentially lighter-weight than invoking DB::Get(). One way
|
|
|
|
// to make this lighter weight is to avoid doing any IOs.
|
|
|
|
// to make this lighter weight is to avoid doing any IOs.
|
|
|
|
// Default implementation here returns true and sets 'value_found' to false
|
|
|
|
// Default implementation here returns true and sets 'value_found' to false
|
|
|
|
virtual bool KeyMayExist(const ReadOptions& options, |
|
|
|
virtual bool KeyMayExist(const ReadOptions& /*options*/, |
|
|
|
ColumnFamilyHandle* column_family, const Slice& key, |
|
|
|
ColumnFamilyHandle* /*column_family*/, |
|
|
|
std::string* value, bool* value_found = nullptr) { |
|
|
|
const Slice& /*key*/, std::string* /*value*/, |
|
|
|
|
|
|
|
bool* value_found = nullptr) { |
|
|
|
if (value_found != nullptr) { |
|
|
|
if (value_found != nullptr) { |
|
|
|
*value_found = false; |
|
|
|
*value_found = false; |
|
|
|
} |
|
|
|
} |
|
|
@ -502,8 +503,8 @@ class DB { |
|
|
|
return CompactRange(options, DefaultColumnFamily(), begin, end); |
|
|
|
return CompactRange(options, DefaultColumnFamily(), begin, end); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
virtual Status SetOptions(ColumnFamilyHandle* column_family, |
|
|
|
virtual Status SetOptions(ColumnFamilyHandle* /*column_family*/, |
|
|
|
const std::unordered_map<std::string, std::string>& new_options) { |
|
|
|
const std::unordered_map<std::string, std::string>& /*new_options*/) { |
|
|
|
return Status::NotSupported("Not implemented"); |
|
|
|
return Status::NotSupported("Not implemented"); |
|
|
|
} |
|
|
|
} |
|
|
|
virtual Status SetOptions( |
|
|
|
virtual Status SetOptions( |
|
|
@ -653,7 +654,8 @@ class DB { |
|
|
|
|
|
|
|
|
|
|
|
// Returns a list of all table files with their level, start key
|
|
|
|
// Returns a list of all table files with their level, start key
|
|
|
|
// and end key
|
|
|
|
// and end key
|
|
|
|
virtual void GetLiveFilesMetaData(std::vector<LiveFileMetaData>* metadata) {} |
|
|
|
virtual void GetLiveFilesMetaData( |
|
|
|
|
|
|
|
std::vector<LiveFileMetaData>* /*metadata*/) {} |
|
|
|
|
|
|
|
|
|
|
|
// Obtains the meta data of the specified column family of the DB.
|
|
|
|
// Obtains the meta data of the specified column family of the DB.
|
|
|
|
// Status::NotFound() will be returned if the current DB does not have
|
|
|
|
// Status::NotFound() will be returned if the current DB does not have
|
|
|
@ -662,8 +664,8 @@ class DB { |
|
|
|
// If cf_name is not specified, then the metadata of the default
|
|
|
|
// If cf_name is not specified, then the metadata of the default
|
|
|
|
// column family will be returned.
|
|
|
|
// column family will be returned.
|
|
|
|
virtual void GetColumnFamilyMetaData( |
|
|
|
virtual void GetColumnFamilyMetaData( |
|
|
|
ColumnFamilyHandle* column_family, |
|
|
|
ColumnFamilyHandle* /*column_family*/, |
|
|
|
ColumnFamilyMetaData* metadata) {} |
|
|
|
ColumnFamilyMetaData* /*metadata*/) {} |
|
|
|
|
|
|
|
|
|
|
|
// Get the metadata of the default column family.
|
|
|
|
// Get the metadata of the default column family.
|
|
|
|
void GetColumnFamilyMetaData( |
|
|
|
void GetColumnFamilyMetaData( |
|
|
|