InnoDB Plugin
1.0
|
Go to the source code of this file.
Macros | |
#define | FLST_BASE_NODE_SIZE (4 + 2 * FIL_ADDR_SIZE) |
#define | FLST_NODE_SIZE (2 * FIL_ADDR_SIZE) |
Typedefs | |
typedef byte | flst_base_node_t |
typedef byte | flst_node_t |
Functions | |
UNIV_INLINE void | flst_init (flst_base_node_t *base, mtr_t *mtr) |
UNIV_INTERN void | flst_add_last (flst_base_node_t *base, flst_node_t *node, mtr_t *mtr) |
UNIV_INTERN void | flst_add_first (flst_base_node_t *base, flst_node_t *node, mtr_t *mtr) |
UNIV_INTERN void | flst_insert_after (flst_base_node_t *base, flst_node_t *node1, flst_node_t *node2, mtr_t *mtr) |
UNIV_INTERN void | flst_insert_before (flst_base_node_t *base, flst_node_t *node2, flst_node_t *node3, mtr_t *mtr) |
UNIV_INTERN void | flst_remove (flst_base_node_t *base, flst_node_t *node2, mtr_t *mtr) |
UNIV_INTERN void | flst_cut_end (flst_base_node_t *base, flst_node_t *node2, ulint n_nodes, mtr_t *mtr) |
UNIV_INTERN void | flst_truncate_end (flst_base_node_t *base, flst_node_t *node2, ulint n_nodes, mtr_t *mtr) |
UNIV_INLINE ulint | flst_get_len (const flst_base_node_t *base, mtr_t *mtr) |
UNIV_INLINE fil_addr_t | flst_get_first (const flst_base_node_t *base, mtr_t *mtr) |
UNIV_INLINE fil_addr_t | flst_get_last (const flst_base_node_t *base, mtr_t *mtr) |
UNIV_INLINE fil_addr_t | flst_get_next_addr (const flst_node_t *node, mtr_t *mtr) |
UNIV_INLINE fil_addr_t | flst_get_prev_addr (const flst_node_t *node, mtr_t *mtr) |
UNIV_INLINE void | flst_write_addr (fil_faddr_t *faddr, fil_addr_t addr, mtr_t *mtr) |
UNIV_INLINE fil_addr_t | flst_read_addr (const fil_faddr_t *faddr, mtr_t *mtr) |
UNIV_INTERN ibool | flst_validate (const flst_base_node_t *base, mtr_t *mtr1) |
UNIV_INTERN void | flst_print (const flst_base_node_t *base, mtr_t *mtr) |
File-based list utilities
Created 11/28/1995 Heikki Tuuri
UNIV_INTERN void flst_add_first | ( | flst_base_node_t * | base, |
flst_node_t * | node, | ||
mtr_t * | mtr | ||
) |
Adds a node as the first node in a list. in: mini-transaction handle
base | in: pointer to base node of list |
node | in: node to add |
UNIV_INTERN void flst_add_last | ( | flst_base_node_t * | base, |
flst_node_t * | node, | ||
mtr_t * | mtr | ||
) |
Adds a node as the last node in a list. in: mini-transaction handle
base | in: pointer to base node of list |
node | in: node to add |
UNIV_INTERN void flst_cut_end | ( | flst_base_node_t * | base, |
flst_node_t * | node2, | ||
ulint | n_nodes, | ||
mtr_t * | mtr | ||
) |
Cuts off the tail of the list, including the node given. The number of nodes which will be removed must be provided by the caller, as this function does not measure the length of the tail. in: mini-transaction handle
base | in: pointer to base node of list |
node2 | in: first node to remove |
n_nodes | in: number of nodes to remove, must be >= 1 |
UNIV_INLINE fil_addr_t flst_get_first | ( | const flst_base_node_t * | base, |
mtr_t * | mtr | ||
) |
Gets list first node address.
Gets list first node address.
base | in: pointer to base node |
mtr | in: mini-transaction handle |
UNIV_INLINE fil_addr_t flst_get_last | ( | const flst_base_node_t * | base, |
mtr_t * | mtr | ||
) |
Gets list last node address.
Gets list last node address.
base | in: pointer to base node |
mtr | in: mini-transaction handle |
UNIV_INLINE ulint flst_get_len | ( | const flst_base_node_t * | base, |
mtr_t * | mtr | ||
) |
Gets list length.
Gets list length.
base | in: pointer to base node |
mtr | in: mini-transaction handle |
UNIV_INLINE fil_addr_t flst_get_next_addr | ( | const flst_node_t * | node, |
mtr_t * | mtr | ||
) |
Gets list next node address.
Gets list next node address.
node | in: pointer to node |
mtr | in: mini-transaction handle |
UNIV_INLINE fil_addr_t flst_get_prev_addr | ( | const flst_node_t * | node, |
mtr_t * | mtr | ||
) |
Gets list prev node address.
Gets list prev node address.
node | in: pointer to node |
mtr | in: mini-transaction handle |
UNIV_INLINE void flst_init | ( | flst_base_node_t * | base, |
mtr_t * | mtr | ||
) |
Initializes a list base node. in: mini-transaction handle
Initializes a list base node.
base | in: pointer to base node |
mtr | in: mini-transaction handle |
UNIV_INTERN void flst_insert_after | ( | flst_base_node_t * | base, |
flst_node_t * | node1, | ||
flst_node_t * | node2, | ||
mtr_t * | mtr | ||
) |
Inserts a node after another in a list. in: mini-transaction handle
base | in: pointer to base node of list |
node1 | in: node to insert after |
node2 | in: node to add |
UNIV_INTERN void flst_insert_before | ( | flst_base_node_t * | base, |
flst_node_t * | node2, | ||
flst_node_t * | node3, | ||
mtr_t * | mtr | ||
) |
Inserts a node before another in a list. in: mini-transaction handle
base | in: pointer to base node of list |
node2 | in: node to insert |
node3 | in: node to insert before |
UNIV_INTERN void flst_print | ( | const flst_base_node_t * | base, |
mtr_t * | mtr | ||
) |
Prints info of a file-based list. in: mtr
base | in: pointer to base node of list |
UNIV_INLINE fil_addr_t flst_read_addr | ( | const fil_faddr_t * | faddr, |
mtr_t * | mtr | ||
) |
Reads a file address.
Reads a file address.
faddr | in: pointer to file faddress |
mtr | in: mini-transaction handle |
UNIV_INTERN void flst_remove | ( | flst_base_node_t * | base, |
flst_node_t * | node2, | ||
mtr_t * | mtr | ||
) |
Removes a node. in: mini-transaction handle
base | in: pointer to base node of list |
node2 | in: node to remove |
UNIV_INTERN void flst_truncate_end | ( | flst_base_node_t * | base, |
flst_node_t * | node2, | ||
ulint | n_nodes, | ||
mtr_t * | mtr | ||
) |
Cuts off the tail of the list, not including the given node. The number of nodes which will be removed must be provided by the caller, as this function does not measure the length of the tail. in: mini-transaction handle
base | in: pointer to base node of list |
node2 | in: first node not to remove |
n_nodes | in: number of nodes to remove |
Validates a file-based list.
base | in: pointer to base node of list |
UNIV_INLINE void flst_write_addr | ( | fil_faddr_t * | faddr, |
fil_addr_t | addr, | ||
mtr_t * | mtr | ||
) |
Writes a file address. in: mini-transaction handle
Writes a file address.
faddr | in: pointer to file faddress |
addr | in: file address |
mtr | in: mini-transaction handle |