Dash Core Source Documentation (0.16.0.1)
Find detailed information regarding the Dash Core source code.
#include <unordered_lru_cache.h>
|
| unordered_lru_cache (size_t _maxSize=MaxSize, size_t _truncateThreshold=TruncateThreshold) |
|
template<typename Value2 > |
void | _emplace (const Key &key, Value2 &&v) |
|
void | emplace (const Key &key, Value &&v) |
|
void | insert (const Key &key, const Value &v) |
|
bool | get (const Key &key, Value &value) |
|
bool | exists (const Key &key) |
|
void | erase (const Key &key) |
|
void | clear () |
|
|
typedef std::unordered_map< Key, std::pair< Value, int64_t >, Hasher > | MapType |
|
template<typename Key, typename Value, typename Hasher, size_t MaxSize = 0, size_t TruncateThreshold = 0>
class unordered_lru_cache< Key, Value, Hasher, MaxSize, TruncateThreshold >
Definition at line 11 of file unordered_lru_cache.h.
◆ MapType
template<typename Key, typename Value, typename Hasher, size_t MaxSize = 0, size_t TruncateThreshold = 0>
typedef std::unordered_map<Key, std::pair<Value, int64_t>, Hasher> unordered_lru_cache< Key, Value, Hasher, MaxSize, TruncateThreshold >::MapType |
|
private |
◆ unordered_lru_cache()
template<typename Key, typename Value, typename Hasher, size_t MaxSize = 0, size_t TruncateThreshold = 0>
◆ _emplace()
template<typename Key, typename Value, typename Hasher, size_t MaxSize = 0, size_t TruncateThreshold = 0>
template<typename Value2 >
void unordered_lru_cache< Key, Value, Hasher, MaxSize, TruncateThreshold >::_emplace |
( |
const Key & |
key, |
|
|
Value2 && |
v |
|
) |
| |
|
inline |
◆ clear()
template<typename Key, typename Value, typename Hasher, size_t MaxSize = 0, size_t TruncateThreshold = 0>
◆ emplace()
template<typename Key, typename Value, typename Hasher, size_t MaxSize = 0, size_t TruncateThreshold = 0>
void unordered_lru_cache< Key, Value, Hasher, MaxSize, TruncateThreshold >::emplace |
( |
const Key & |
key, |
|
|
Value && |
v |
|
) |
| |
|
inline |
◆ erase()
template<typename Key, typename Value, typename Hasher, size_t MaxSize = 0, size_t TruncateThreshold = 0>
void unordered_lru_cache< Key, Value, Hasher, MaxSize, TruncateThreshold >::erase |
( |
const Key & |
key | ) |
|
|
inline |
◆ exists()
template<typename Key, typename Value, typename Hasher, size_t MaxSize = 0, size_t TruncateThreshold = 0>
bool unordered_lru_cache< Key, Value, Hasher, MaxSize, TruncateThreshold >::exists |
( |
const Key & |
key | ) |
|
|
inline |
◆ get()
template<typename Key, typename Value, typename Hasher, size_t MaxSize = 0, size_t TruncateThreshold = 0>
bool unordered_lru_cache< Key, Value, Hasher, MaxSize, TruncateThreshold >::get |
( |
const Key & |
key, |
|
|
Value & |
value |
|
) |
| |
|
inline |
◆ insert()
template<typename Key, typename Value, typename Hasher, size_t MaxSize = 0, size_t TruncateThreshold = 0>
void unordered_lru_cache< Key, Value, Hasher, MaxSize, TruncateThreshold >::insert |
( |
const Key & |
key, |
|
|
const Value & |
v |
|
) |
| |
|
inline |
◆ truncate_if_needed()
template<typename Key, typename Value, typename Hasher, size_t MaxSize = 0, size_t TruncateThreshold = 0>
void unordered_lru_cache< Key, Value, Hasher, MaxSize, TruncateThreshold >::truncate_if_needed |
( |
| ) |
|
|
inlineprivate |
◆ accessCounter
template<typename Key, typename Value, typename Hasher, size_t MaxSize = 0, size_t TruncateThreshold = 0>
int64_t unordered_lru_cache< Key, Value, Hasher, MaxSize, TruncateThreshold >::accessCounter {0} |
|
private |
Definition at line 19 of file unordered_lru_cache.h.
Referenced by unordered_lru_cache< uint256, bool, StaticSaltedHasher, 30000 >::_emplace(), unordered_lru_cache< uint256, bool, StaticSaltedHasher, 30000 >::exists(), and unordered_lru_cache< uint256, bool, StaticSaltedHasher, 30000 >::get().
◆ cacheMap
template<typename Key, typename Value, typename Hasher, size_t MaxSize = 0, size_t TruncateThreshold = 0>
Definition at line 16 of file unordered_lru_cache.h.
Referenced by unordered_lru_cache< uint256, bool, StaticSaltedHasher, 30000 >::_emplace(), unordered_lru_cache< uint256, bool, StaticSaltedHasher, 30000 >::clear(), unordered_lru_cache< uint256, bool, StaticSaltedHasher, 30000 >::erase(), unordered_lru_cache< uint256, bool, StaticSaltedHasher, 30000 >::exists(), unordered_lru_cache< uint256, bool, StaticSaltedHasher, 30000 >::get(), and unordered_lru_cache< uint256, bool, StaticSaltedHasher, 30000 >::truncate_if_needed().
◆ maxSize
template<typename Key, typename Value, typename Hasher, size_t MaxSize = 0, size_t TruncateThreshold = 0>
◆ truncateThreshold
template<typename Key, typename Value, typename Hasher, size_t MaxSize = 0, size_t TruncateThreshold = 0>
size_t unordered_lru_cache< Key, Value, Hasher, MaxSize, TruncateThreshold >::truncateThreshold |
|
private |
The documentation for this class was generated from the following file: