MySQL 8.0.40
Source Code Documentation
|
Container of persisters used in the system. More...
#include <dict0mem.h>
Public Member Functions | |
Persisters () | |
Constructor. More... | |
~Persisters () | |
Destructor. More... | |
Persister * | get (persistent_type_t type) const |
Get the persister object with specified type. More... | |
Persister * | add (persistent_type_t type) |
Add a specified persister of type, we will allocate the Persister if there is no such persister exist, otherwise do nothing and return the existing one. More... | |
void | remove (persistent_type_t type) |
Remove a specified persister of type, we will free the Persister. More... | |
size_t | write (PersistentTableMetadata &metadata, byte *buffer) |
Serialize the metadata to a buffer. More... | |
Private Types | |
typedef std::map< persistent_type_t, Persister *, std::less< persistent_type_t >, ut::allocator< std::pair< const persistent_type_t, Persister * > > > | persisters_t |
Private Attributes | |
persisters_t | m_persisters |
A map to store all persisters needed. More... | |
Container of persisters used in the system.
Currently we don't need to protect this object since we only initialize it at very beginning and destroy it in the end. During the server running, we only get the persisters
|
private |
|
inline |
Constructor.
Persisters::~Persisters | ( | ) |
Destructor.
Persister * Persisters::add | ( | persistent_type_t | type | ) |
Add a specified persister of type, we will allocate the Persister if there is no such persister exist, otherwise do nothing and return the existing one.
[in] | type | persister type |
Persister * Persisters::get | ( | persistent_type_t | type | ) | const |
Get the persister object with specified type.
[in] | type | persister type |
void Persisters::remove | ( | persistent_type_t | type | ) |
Remove a specified persister of type, we will free the Persister.
[in] | type | persister type |
size_t Persisters::write | ( | PersistentTableMetadata & | metadata, |
byte * | buffer | ||
) |
Serialize the metadata to a buffer.
[in] | metadata | metadata to serialize |
[out] | buffer | buffer to store the serialized metadata |
|
private |
A map to store all persisters needed.