|
|
|
@ -407,7 +407,11 @@ class DB { |
|
|
|
|
return Put(options, DefaultColumnFamily(), key, ts, value); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
// UNDER CONSTRUCTION -- DO NOT USE
|
|
|
|
|
// Set the database entry for "key" in the column family specified by
|
|
|
|
|
// "column_family" to the wide-column entity defined by "columns". If the key
|
|
|
|
|
// already exists in the column family, it will be overwritten.
|
|
|
|
|
//
|
|
|
|
|
// Returns OK on success, and a non-OK status on error.
|
|
|
|
|
virtual Status PutEntity(const WriteOptions& options, |
|
|
|
|
ColumnFamilyHandle* column_family, const Slice& key, |
|
|
|
|
const WideColumns& columns); |
|
|
|
@ -511,16 +515,17 @@ class DB { |
|
|
|
|
// Note: consider setting options.sync = true.
|
|
|
|
|
virtual Status Write(const WriteOptions& options, WriteBatch* updates) = 0; |
|
|
|
|
|
|
|
|
|
// If the database contains an entry for "key" store the
|
|
|
|
|
// corresponding value in *value and return OK.
|
|
|
|
|
// If the column family specified by "column_family" contains an entry for
|
|
|
|
|
// "key", return the corresponding value in "*value". If the entry is a plain
|
|
|
|
|
// key-value, return the value as-is; if it is a wide-column entity, return
|
|
|
|
|
// the value of its default anonymous column (see kDefaultWideColumnName) if
|
|
|
|
|
// any, or an empty value otherwise.
|
|
|
|
|
//
|
|
|
|
|
// If timestamp is enabled and a non-null timestamp pointer is passed in,
|
|
|
|
|
// timestamp is returned.
|
|
|
|
|
//
|
|
|
|
|
// If there is no entry for "key" leave *value unchanged and return
|
|
|
|
|
// a status for which Status::IsNotFound() returns true.
|
|
|
|
|
//
|
|
|
|
|
// May return some other Status on an error.
|
|
|
|
|
// Returns OK on success. Returns NotFound and an empty value in "*value" if
|
|
|
|
|
// there is no entry for "key". Returns some other non-OK status on error.
|
|
|
|
|
virtual inline Status Get(const ReadOptions& options, |
|
|
|
|
ColumnFamilyHandle* column_family, const Slice& key, |
|
|
|
|
std::string* value) { |
|
|
|
@ -567,7 +572,15 @@ class DB { |
|
|
|
|
return Get(options, DefaultColumnFamily(), key, value, timestamp); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
// UNDER CONSTRUCTION -- DO NOT USE
|
|
|
|
|
// If the column family specified by "column_family" contains an entry for
|
|
|
|
|
// "key", return it as a wide-column entity in "*columns". If the entry is a
|
|
|
|
|
// wide-column entity, return it as-is; if it is a plain key-value, return it
|
|
|
|
|
// as an entity with a single anonymous column (see kDefaultWideColumnName)
|
|
|
|
|
// which contains the value.
|
|
|
|
|
//
|
|
|
|
|
// Returns OK on success. Returns NotFound and an empty wide-column entity in
|
|
|
|
|
// "*columns" if there is no entry for "key". Returns some other non-OK status
|
|
|
|
|
// on error.
|
|
|
|
|
virtual Status GetEntity(const ReadOptions& /* options */, |
|
|
|
|
ColumnFamilyHandle* /* column_family */, |
|
|
|
|
const Slice& /* key */, |
|
|
|
|