Kagome
Polkadot Runtime Engine in C++17
|
#include <runtime_instances_pool.hpp>
Classes | |
struct | CacheEntry |
Public Member Functions | |
SmallLruCache (size_t max_size) | |
std::optional< std::reference_wrapper< const Value > > | get (const Key &key) |
template<typename ValueArg > | |
void | put (const Key &key, ValueArg &&value) |
Private Member Functions | |
void | handleTicksOverflow () |
Private Attributes | |
const size_t | kMaxSize |
PriorityType | ticks_ {} |
std::vector< CacheEntry > | cache_ |
LRU cache designed for small amounts of data (as its get() is O(N))
Definition at line 18 of file runtime_instances_pool.hpp.
|
inline |
Definition at line 32 of file runtime_instances_pool.hpp.
|
inline |
Definition at line 37 of file runtime_instances_pool.hpp.
|
inlineprivate |
Definition at line 65 of file runtime_instances_pool.hpp.
|
inline |
Definition at line 52 of file runtime_instances_pool.hpp.
|
private |
Definition at line 79 of file runtime_instances_pool.hpp.
|
private |
Definition at line 75 of file runtime_instances_pool.hpp.
|
private |
Definition at line 78 of file runtime_instances_pool.hpp.