MySQL 9.7.0
Source Code Documentation
mysql_harness::utility::cache::Cache< Key, Value, Algorithm > Class Template Reference

#include <cache.h>

Public Member Functions

template<typename... Args>
 Cache (Args &&...args)
 
void remove (const Key &key)
 
Value * get_cached_value (const Key &key)
 
Value * set (const Key &key, Value &&value)
 
Value * set (const Key &key, const Value &value)
 
Containerget_container ()
 
bool is_full () const
 

Private Types

using Container = std::map< Key, Value >
 

Private Member Functions

template<typename V >
Value * set_impl (const Key &key, V &&value)
 

Private Attributes

Algorithm key_cache_
 
Container container_
 

Member Typedef Documentation

◆ Container

template<typename Key , typename Value , typename Algorithm >
using mysql_harness::utility::cache::Cache< Key, Value, Algorithm >::Container = std::map<Key, Value>
private

Constructor & Destructor Documentation

◆ Cache()

template<typename Key , typename Value , typename Algorithm >
template<typename... Args>
mysql_harness::utility::cache::Cache< Key, Value, Algorithm >::Cache ( Args &&...  args)
inlineexplicit

Member Function Documentation

◆ get_cached_value()

template<typename Key , typename Value , typename Algorithm >
Value * mysql_harness::utility::cache::Cache< Key, Value, Algorithm >::get_cached_value ( const Key &  key)
inline

◆ get_container()

template<typename Key , typename Value , typename Algorithm >
Container & mysql_harness::utility::cache::Cache< Key, Value, Algorithm >::get_container ( )
inline

◆ is_full()

template<typename Key , typename Value , typename Algorithm >
bool mysql_harness::utility::cache::Cache< Key, Value, Algorithm >::is_full ( ) const
inline

◆ remove()

template<typename Key , typename Value , typename Algorithm >
void mysql_harness::utility::cache::Cache< Key, Value, Algorithm >::remove ( const Key &  key)
inline

◆ set() [1/2]

template<typename Key , typename Value , typename Algorithm >
Value * mysql_harness::utility::cache::Cache< Key, Value, Algorithm >::set ( const Key &  key,
const Value &  value 
)
inline

◆ set() [2/2]

template<typename Key , typename Value , typename Algorithm >
Value * mysql_harness::utility::cache::Cache< Key, Value, Algorithm >::set ( const Key &  key,
Value &&  value 
)
inline

◆ set_impl()

template<typename Key , typename Value , typename Algorithm >
template<typename V >
Value * mysql_harness::utility::cache::Cache< Key, Value, Algorithm >::set_impl ( const Key &  key,
V &&  value 
)
inlineprivate

Member Data Documentation

◆ container_

template<typename Key , typename Value , typename Algorithm >
Container mysql_harness::utility::cache::Cache< Key, Value, Algorithm >::container_
private

◆ key_cache_

template<typename Key , typename Value , typename Algorithm >
Algorithm mysql_harness::utility::cache::Cache< Key, Value, Algorithm >::key_cache_
private

The documentation for this class was generated from the following file: