#include <cache.hpp>
|
typedef std::list< Key > | list |
|
typedef std::unordered_map< Key, std::pair< Value, typename list::iterator > > | map |
|
|
| Cache (size_t _capacity) |
|
void | put (const Key &key, const Value &value) |
|
Option< Value > | get (const Key &key) |
|
Option< Value > | erase (const Key &key) |
|
size_t | size () const |
|
|
std::ostream & | operator<< (std::ostream &stream, const Cache< Key, Value > &c) |
|
template<typename Key, typename Value>
typedef std::list<Key> Cache< Key, Value >::list |
template<typename Key, typename Value>
typedef std::unordered_map< Key, std::pair<Value, typename list::iterator> > Cache< Key, Value >::map |
template<typename Key, typename Value>
template<typename Key, typename Value>
Option<Value> Cache< Key, Value >::erase |
( |
const Key & |
key | ) |
|
|
inline |
template<typename Key, typename Value>
Option<Value> Cache< Key, Value >::get |
( |
const Key & |
key | ) |
|
|
inline |
template<typename Key, typename Value>
void Cache< Key, Value >::put |
( |
const Key & |
key, |
|
|
const Value & |
value |
|
) |
| |
|
inline |
template<typename Key, typename Value>
size_t Cache< Key, Value >::size |
( |
| ) |
const |
|
inline |
template<typename Key, typename Value>
std::ostream& operator<< |
( |
std::ostream & |
stream, |
|
|
const Cache< Key, Value > & |
c |
|
) |
| |
|
friend |
The documentation for this class was generated from the following file: