MySQL 8.0.37
Source Code Documentation
sp_cache Class Reference

Classes

struct  sp_head_deleter
 

Public Member Functions

 sp_cache ()
 
 ~sp_cache ()=default
 
bool insert (sp_head *sp)
 Inserts a sp_head object into a hash table. More...
 
sp_headlookup (char *name, size_t namelen)
 
void remove (sp_head *sp)
 
void enforce_limit (ulong upper_limit_for_elements)
 Remove all elements from a stored routine cache if the current number of elements exceeds the argument value. More...
 

Private Attributes

collation_unordered_map< std::string, std::unique_ptr< sp_head, sp_head_deleter > > m_hashtable
 

Constructor & Destructor Documentation

◆ sp_cache()

sp_cache::sp_cache ( )
inline

◆ ~sp_cache()

sp_cache::~sp_cache ( )
default

Member Function Documentation

◆ enforce_limit()

void sp_cache::enforce_limit ( ulong  upper_limit_for_elements)
inline

Remove all elements from a stored routine cache if the current number of elements exceeds the argument value.

Parameters
[in]upper_limit_for_elementsSoft upper limit of elements that can be stored in the cache.

◆ insert()

bool sp_cache::insert ( sp_head sp)
inline

Inserts a sp_head object into a hash table.

Returns
Success status
true Failure
false Success

◆ lookup()

sp_head * sp_cache::lookup ( char *  name,
size_t  namelen 
)
inline

◆ remove()

void sp_cache::remove ( sp_head sp)
inline

Member Data Documentation

◆ m_hashtable

collation_unordered_map<std::string, std::unique_ptr<sp_head, sp_head_deleter> > sp_cache::m_hashtable
private

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