![]() |
MySQL 9.2.0
Source Code Documentation
|
The LOB data page carrying the user data. More...
#include <lob0pages.h>
Public Member Functions | |
data_page_t ()=default | |
data_page_t (buf_block_t *block, mtr_t *mtr) | |
Constructor. More... | |
data_page_t (buf_block_t *block, mtr_t *mtr, dict_index_t *index) | |
data_page_t (mtr_t *mtr, dict_index_t *index) | |
data_page_t (buf_block_t *block) | |
Constructor. More... | |
buf_block_t * | alloc (mtr_t *alloc_mtr, bool is_bulk) |
Allocate a LOB data page. More... | |
buf_block_t * | load_x (page_no_t page_no) |
void | set_version_0 () |
void | dealloc () |
void | set_page_type () |
void | set_trx_id (trx_id_t id) |
void | set_trx_id_no_redo (trx_id_t id) |
Write the trx identifier to the header, without generating redo log. More... | |
byte * | data_begin () const |
buf_block_t * | replace (trx_t *trx, ulint offset, const byte *&ptr, ulint &want, mtr_t *mtr) |
Create a new data page and replace some or all parts of the old data with data. More... | |
void | replace_inline (ulint offset, const byte *&ptr, ulint &want, mtr_t *mtr) |
Replace some or all parts of the data inline. More... | |
ulint | get_data_len () const |
void | set_data_len (ulint len) |
ulint | read (ulint offset, byte *ptr, ulint want) |
Read data from the data page. More... | |
ulint | write (const byte *&data, ulint &len) |
Write data into a data page. More... | |
ulint | append (trx_id_t trxid, byte *&data, ulint &len) |
Append given data in data page. More... | |
std::pair< ulint, byte * > | insert_middle (trx_t *trx, ulint offset, byte *&data, ulint &len, buf_block_t *&new_block) |
buf_block_t * | remove_middle (trx_t *trx, ulint offset, ulint &len) |
ulint | max_space_available () const |
ulint | space_left () const |
![]() | |
basic_page_t () | |
basic_page_t (buf_block_t *block, mtr_t *mtr) | |
basic_page_t (buf_block_t *block, mtr_t *mtr, dict_index_t *index) | |
void | set_space_id_no_redo (space_id_t space_id) |
Update the space identifier to given value without generating any redo log records. More... | |
page_no_t | get_page_no () const |
Get page number of the current page. More... | |
page_id_t | get_page_id () const |
Get the page id of the current page. More... | |
void | set_next_page (page_no_t page_no, mtr_t *mtr) |
Set the FIL_PAGE_NEXT to the given page number, using the given mini transaction context. More... | |
void | set_next_page (page_no_t page_no) |
Set the FIL_PAGE_NEXT to the given page number. More... | |
void | set_next_page_null () |
Set the FIL_PAGE_NEXT to FIL_NULL. More... | |
page_no_t | get_next_page () |
page_type_t | get_page_type () const |
byte * | frame () const |
flst_node_t * | get_flst_node (const fil_addr_t &addr) |
ulint | max_space_available () |
buf_block_t * | get_block () const noexcept |
Get the underlying buffer block. More... | |
void | set_block (buf_block_t *block) |
void | set_mtr (mtr_t *mtr) |
Static Public Member Functions | |
static ulint | payload () |
![]() | |
static ulint | payload () |
Static Public Attributes | |
static const ulint | OFFSET_VERSION = FIL_PAGE_DATA |
static const ulint | OFFSET_DATA_LEN = OFFSET_VERSION + 1 |
static const ulint | OFFSET_TRX_ID = OFFSET_DATA_LEN + 4 |
static const ulint | LOB_PAGE_DATA = OFFSET_TRX_ID + 6 |
Additional Inherited Members | |
![]() | |
buf_block_t * | m_block {nullptr} |
mtr_t * | m_mtr {nullptr} |
dict_index_t * | m_index {nullptr} |
The LOB data page carrying the user data.
|
default |
|
inline |
Constructor.
|
inline |
|
inline |
|
inline |
Constructor.
[in] | block | the buffer block. |
buf_block_t * lob::data_page_t::alloc | ( | mtr_t * | alloc_mtr, |
bool | is_bulk | ||
) |
Allocate a LOB data page.
[in] | alloc_mtr | Mini-transaction to be used for allocation of LOB page. |
[in] | is_bulk | true if bulk operation. |
Append given data in data page.
[in] | trxid | transaction doing append. |
[in,out] | data | data to be appended. |
[in,out] | len | length of data. |
|
inline |
|
inline |
|
inline |
std::pair< ulint, byte * > lob::data_page_t::insert_middle | ( | trx_t * | trx, |
ulint | offset, | ||
byte *& | data, | ||
ulint & | len, | ||
buf_block_t *& | new_block | ||
) |
buf_block_t * lob::data_page_t::load_x | ( | page_no_t | page_no | ) |
|
inline |
|
inlinestatic |
Read data from the data page.
[in] | offset | read begins at this offset. |
[out] | ptr | the output buffer. |
[in] | want | bytes to read |
buf_block_t * lob::data_page_t::remove_middle | ( | trx_t * | trx, |
ulint | offset, | ||
ulint & | len | ||
) |
buf_block_t * lob::data_page_t::replace | ( | trx_t * | trx, |
ulint | offset, | ||
const byte *& | ptr, | ||
ulint & | want, | ||
mtr_t * | mtr | ||
) |
Create a new data page and replace some or all parts of the old data with data.
[in] | trx | Current transaction. |
[in] | offset | Offset where replace begins. |
[in,out] | ptr | Pointer to new data. |
[in] | want | Amount of data the caller wants to replace. |
[in] | mtr | Mini-transaction context. |
Allocate a new data page.
Copy contents from old page to new page.
Copy the new data to new page.
Copy contents from old page to new page.
void lob::data_page_t::replace_inline | ( | ulint | offset, |
const byte *& | ptr, | ||
ulint & | want, | ||
mtr_t * | mtr | ||
) |
Replace some or all parts of the data inline.
[in] | offset | Offset where replace begins. |
[in,out] | ptr | Pointer to new data. |
[in] | want | Amount of data the caller wants to replace. |
[in] | mtr | Mini-transaction context. |
Copy the new data to page.
|
inline |
|
inline |
|
inline |
|
inline |
Write the trx identifier to the header, without generating redo log.
[in] | id | the transaction identifier. |
|
inline |
ulint lob::data_page_t::space_left | ( | ) | const |
Write data into a data page.
[in,out] | data | the data to be written. it will be updated to point to the byte not yet written. |
[in,out] | len | length of data to be written. |
|
static |
|
static |
|
static |
|
static |