InnoDB Plugin  1.0
Macros | Functions
fut0lst.ic File Reference
#include "fut0fut.h"
#include "mtr0log.h"
#include "buf0buf.h"
Include dependency graph for fut0lst.ic:
This graph shows which files directly or indirectly include this file:

Macros

#define FLST_PREV
#define FLST_NEXT
#define FLST_LEN   0 /* 32-bit list length field */
#define FLST_FIRST
#define FLST_LAST

Functions

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_INLINE void flst_init (flst_base_node_t *base, 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)

Detailed Description

File-based list utilities

Created 11/28/1995 Heikki Tuuri

Macro Definition Documentation

#define FLST_FIRST
Value:
4 /* 6-byte address of the first element
of the list; undefined if empty list */
#define FLST_LAST
Value:
(4 + FIL_ADDR_SIZE) /* 6-byte address of the
last element of the list; undefined
if empty list */
#define FLST_NEXT
Value:
FIL_ADDR_SIZE /* 6-byte address of the next
list element; the page part of address
is FIL_NULL, if no next element */
#define FLST_PREV
Value:
0 /* 6-byte address of the previous list element;
the page part of address is FIL_NULL, if no
previous element */

Function Documentation

UNIV_INLINE fil_addr_t flst_get_first ( const flst_base_node_t *  base,
mtr_t mtr 
)

Gets list first node address.

Returns
file address
Parameters
basein: pointer to base node
mtrin: 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.

Returns
file address
Parameters
basein: pointer to base node
mtrin: mini-transaction handle
UNIV_INLINE ulint flst_get_len ( const flst_base_node_t *  base,
mtr_t mtr 
)

Gets list length.

Returns
length
Parameters
basein: pointer to base node
mtrin: 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.

Returns
file address
Parameters
nodein: pointer to node
mtrin: 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.

Returns
file address
Parameters
nodein: pointer to node
mtrin: mini-transaction handle
UNIV_INLINE void flst_init ( flst_base_node_t *  base,
mtr_t mtr 
)

Initializes a list base node.

Parameters
basein: pointer to base node
mtrin: mini-transaction handle
UNIV_INLINE fil_addr_t flst_read_addr ( const fil_faddr_t faddr,
mtr_t mtr 
)

Reads a file address.

Returns
file address
Parameters
faddrin: pointer to file faddress
mtrin: mini-transaction handle
UNIV_INLINE void flst_write_addr ( fil_faddr_t faddr,
fil_addr_t  addr,
mtr_t mtr 
)

Writes a file address.

Parameters
faddrin: pointer to file faddress
addrin: file address
mtrin: mini-transaction handle