Definition at line 26 of file cache_test.cc.
§ CacheTest()
| leveldb::CacheTest::CacheTest |
( |
| ) |
|
|
inline |
Definition at line 40 of file cache_test.cc.
static CacheTest * current_
Cache * NewLRUCache(size_t capacity)
static const int kCacheSize
§ ~CacheTest()
| leveldb::CacheTest::~CacheTest |
( |
| ) |
|
|
inline |
§ Deleter()
| static void leveldb::CacheTest::Deleter |
( |
const Slice & |
key, |
|
|
void * |
v |
|
) |
| |
|
inlinestatic |
Definition at line 30 of file cache_test.cc.
static int DecodeKey(const Slice &k)
static int DecodeValue(void *v)
std::vector< int > deleted_values_
static CacheTest * current_
std::vector< int > deleted_keys_
§ Erase()
| void leveldb::CacheTest::Erase |
( |
int |
key | ) |
|
|
inline |
Definition at line 67 of file cache_test.cc.
static const char * EncodeKey(std::string *scratch, const Slice &target)
virtual void Erase(const Slice &key)=0
§ Insert()
| void leveldb::CacheTest::Insert |
( |
int |
key, |
|
|
int |
value, |
|
|
int |
charge = 1 |
|
) |
| |
|
inline |
Definition at line 57 of file cache_test.cc.
virtual Handle * Insert(const Slice &key, void *value, size_t charge, void(*deleter)(const Slice &key, void *value))=0
static void Deleter(const Slice &key, void *v)
virtual void Release(Handle *handle)=0
static const char * EncodeKey(std::string *scratch, const Slice &target)
static void * EncodeValue(uintptr_t v)
§ InsertAndReturnHandle()
| Cache::Handle* leveldb::CacheTest::InsertAndReturnHandle |
( |
int |
key, |
|
|
int |
value, |
|
|
int |
charge = 1 |
|
) |
| |
|
inline |
Definition at line 62 of file cache_test.cc.
virtual Handle * Insert(const Slice &key, void *value, size_t charge, void(*deleter)(const Slice &key, void *value))=0
static void Deleter(const Slice &key, void *v)
static const char * EncodeKey(std::string *scratch, const Slice &target)
static void * EncodeValue(uintptr_t v)
§ Lookup()
| int leveldb::CacheTest::Lookup |
( |
int |
key | ) |
|
|
inline |
Definition at line 48 of file cache_test.cc.
virtual void Release(Handle *handle)=0
virtual void * Value(Handle *handle)=0
static const char * EncodeKey(std::string *scratch, const Slice &target)
static int DecodeValue(void *v)
virtual Handle * Lookup(const Slice &key)=0
§ cache_
| Cache* leveldb::CacheTest::cache_ |
§ current_
§ deleted_keys_
| std::vector<int> leveldb::CacheTest::deleted_keys_ |
§ deleted_values_
| std::vector<int> leveldb::CacheTest::deleted_values_ |
§ kCacheSize
| const int leveldb::CacheTest::kCacheSize = 1000 |
|
static |
The documentation for this class was generated from the following file: