#include <ug_lru_cache.h>
Classes | |
struct | Record |
Public Types | |
typedef boost::unordered_map < KEY, uint32_t > | map_t |
Public Member Functions | |
LRU_Cache (size_t capacity=1) | |
size_t | capacity () const |
size_t | size () const |
void | reserve (size_t s) |
SPTR< VAL > | get (KEY const &key) |
void | set (KEY const &key, SPTR< VAL > const &ptr) |
Definition at line 19 of file ug_lru_cache.h.
typedef boost::unordered_map<KEY,uint32_t> lru_cache::LRU_Cache< KEY, VAL >::map_t |
Definition at line 22 of file ug_lru_cache.h.
lru_cache::LRU_Cache< KEY, VAL >::LRU_Cache | ( | size_t | capacity = 1 |
) | [inline] |
Definition at line 62 of file ug_lru_cache.h.
size_t lru_cache::LRU_Cache< KEY, VAL >::capacity | ( | ) | const [inline] |
Definition at line 63 of file ug_lru_cache.h.
Referenced by lru_cache::LRU_Cache< uint64_t, vec_ppair >::LRU_Cache().
SPTR<VAL> lru_cache::LRU_Cache< KEY, VAL >::get | ( | KEY const & | key | ) | [inline] |
Definition at line 68 of file ug_lru_cache.h.
Referenced by Moses::sapt::StatsCollector< Token >::process().
void lru_cache::LRU_Cache< KEY, VAL >::reserve | ( | size_t | s | ) | [inline] |
Definition at line 65 of file ug_lru_cache.h.
Referenced by lru_cache::LRU_Cache< uint64_t, vec_ppair >::LRU_Cache().
void lru_cache::LRU_Cache< KEY, VAL >::set | ( | KEY const & | key, | |
SPTR< VAL > const & | ptr | |||
) | [inline] |
Definition at line 83 of file ug_lru_cache.h.
Referenced by Moses::sapt::StatsCollector< Token >::process().
size_t lru_cache::LRU_Cache< KEY, VAL >::size | ( | ) | const [inline] |
Definition at line 64 of file ug_lru_cache.h.