18 #ifndef STORAGE_LEVELDB_INCLUDE_CACHE_H_ 19 #define STORAGE_LEVELDB_INCLUDE_CACHE_H_ 53 void (*deleter)(
const Slice&
key,
void* value)) = 0;
98 void Unref(Handle* e);
110 #endif // STORAGE_LEVELDB_INCLUDE_CACHE_H_ void LRU_Append(Handle *e)
virtual Handle * Insert(const Slice &key, void *value, size_t charge, void(*deleter)(const Slice &key, void *value))=0
Definition: autocompact_test.cc:11
virtual uint64_t NewId()=0
virtual void Release(Handle *handle)=0
virtual void * Value(Handle *handle)=0
Rep * rep_
Definition: cache.h:100
void LRU_Remove(Handle *e)
virtual Handle * Lookup(const Slice &key)=0
unsigned long long uint64_t
Definition: stdint.h:22
Cache()
Definition: cache.h:34
virtual size_t TotalCharge() const =0
void operator=(const Cache &)
Cache * NewLRUCache(size_t capacity)
Definition: cache.cc:401
virtual ~Cache()
Definition: cache.cc:16
virtual void Erase(const Slice &key)=0
virtual void Prune()
Definition: cache.h:89