|
MySQL 5.6.14 Source Code Document
|
#include "univ.i"#include "mtr0mtr.h"#include "mtr0log.h"#include "ut0byte.h"#include "buf0buf.h"#include "fsp0fsp.h"#include "dict0dict.h"#include "dict0boot.ic"

Go to the source code of this file.
Macros | |
| #define | DICT_HDR_SPACE 0 /* the SYSTEM tablespace */ |
| #define | DICT_HDR_PAGE_NO FSP_DICT_HDR_PAGE_NO |
| #define | DICT_TABLES_ID 1 |
| #define | DICT_COLUMNS_ID 2 |
| #define | DICT_INDEXES_ID 3 |
| #define | DICT_FIELDS_ID 4 |
| #define | DICT_TABLE_IDS_ID 5 |
| #define | DICT_HDR_FIRST_ID |
| #define | DICT_HDR FSEG_PAGE_DATA |
| #define | DICT_HDR_ROW_ID 0 /* The latest assigned row id */ |
| #define | DICT_HDR_TABLE_ID 8 /* The latest assigned table id */ |
| #define | DICT_HDR_INDEX_ID 16 /* The latest assigned index id */ |
| #define | DICT_HDR_MAX_SPACE_ID 24 /* The latest assigned space id,or 0*/ |
| #define | DICT_HDR_MIX_ID_LOW 28 /* Obsolete,always DICT_HDR_FIRST_ID*/ |
| #define | DICT_HDR_TABLES 32 /* Root of SYS_TABLES clust index */ |
| #define | DICT_HDR_TABLE_IDS 36 /* Root of SYS_TABLE_IDS sec index */ |
| #define | DICT_HDR_COLUMNS 40 /* Root of SYS_COLUMNS clust index */ |
| #define | DICT_HDR_INDEXES 44 /* Root of SYS_INDEXES clust index */ |
| #define | DICT_HDR_FIELDS 48 /* Root of SYS_FIELDS clust index */ |
| #define | DICT_HDR_FSEG_HEADER |
| #define | DICT_FLD_LEN_SPACE 4 |
| #define | DICT_FLD_LEN_FLAGS 4 |
| #define | DICT_HDR_ROW_ID_WRITE_MARGIN 256 |
Typedefs | |
| typedef byte | dict_hdr_t |
Functions | |
| UNIV_INTERN dict_hdr_t * | dict_hdr_get (mtr_t *mtr) |
| UNIV_INTERN void | dict_hdr_get_new_id (table_id_t *table_id, index_id_t *index_id, ulint *space_id) |
| UNIV_INTERN void | dict_hdr_flush_row_id (void) |
| UNIV_INLINE row_id_t | dict_sys_get_new_row_id (void) |
| UNIV_INLINE row_id_t | dict_sys_read_row_id (const byte *field) |
| UNIV_INLINE void | dict_sys_write_row_id (byte *field, row_id_t row_id) |
| UNIV_INTERN dberr_t | dict_boot (void) __attribute__((warn_unused_result)) |
| UNIV_INTERN dberr_t | dict_create (void) __attribute__((warn_unused_result)) |
| UNIV_INLINE bool | dict_is_sys_table (table_id_t id) __attribute__((warn_unused_result)) |
| #define DICT_HDR_FIRST_ID |
Definition at line 131 of file dict0boot.h.
| #define DICT_HDR_FSEG_HEADER |
Definition at line 149 of file dict0boot.h.
| UNIV_INTERN dberr_t dict_boot | ( | void | ) |
Initializes the data dictionary memory structures when the database is started. This function is also called when the data dictionary is created.
Definition at line 247 of file dict0boot.cc.


| UNIV_INTERN dberr_t dict_create | ( | void | ) |
Creates and initializes the data dictionary at the server bootstrap.
Definition at line 494 of file dict0boot.cc.

| UNIV_INTERN void dict_hdr_flush_row_id | ( | void | ) |
Writes the current value of the row id counter to the dictionary header file page.
Definition at line 115 of file dict0boot.cc.

| UNIV_INTERN dict_hdr_t* dict_hdr_get | ( | mtr_t * | mtr | ) |
Gets a pointer to the dictionary header and x-latches its page.
Gets a pointer to the dictionary header and x-latches its page.
| mtr | in: mtr |
Definition at line 47 of file dict0boot.cc.

| UNIV_INTERN void dict_hdr_get_new_id | ( | table_id_t * | table_id, |
| index_id_t * | index_id, | ||
| ulint * | space_id | ||
| ) |
Returns a new table, index, or space id. out: space id (not assigned if NULL)
Returns a new table, index, or space id.
| table_id | out: table id (not assigned if NULL) |
| index_id | out: index id (not assigned if NULL) |
| space_id | out: space id (not assigned if NULL) |
Definition at line 67 of file dict0boot.cc.


| UNIV_INLINE bool dict_is_sys_table | ( | table_id_t | id | ) |
Check if a table id belongs to system table.
| id | in: table id to check |
| UNIV_INLINE row_id_t dict_sys_get_new_row_id | ( | void | ) |
Returns a new row id.
| UNIV_INLINE row_id_t dict_sys_read_row_id | ( | const byte * | field | ) |
Reads a row id from a record or other 6-byte stored form.
| UNIV_INLINE void dict_sys_write_row_id | ( | byte * | field, |
| row_id_t | row_id | ||
| ) |
Writes a row id to a record or other 6-byte stored form. in: row id
| field | in: record field |