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

Macros

#define LIMIT_OPTIMISTIC_INSERT_DEBUG(NREC, CODE)

Functions

UNIV_INLINE page_cur_tbtr_cur_get_page_cur (const btr_cur_t *cursor)
UNIV_INLINE buf_block_tbtr_cur_get_block (const btr_cur_t *cursor)
UNIV_INLINE rec_t * btr_cur_get_rec (const btr_cur_t *cursor)
UNIV_INLINE page_zip_des_tbtr_cur_get_page_zip (btr_cur_t *cursor)
UNIV_INLINE void btr_cur_invalidate (btr_cur_t *cursor)
UNIV_INLINE page_tbtr_cur_get_page (btr_cur_t *cursor)
UNIV_INLINE void btr_cur_position (dict_index_t *index, rec_t *rec, buf_block_t *block, btr_cur_t *cursor)
UNIV_INLINE ibool btr_cur_compress_recommendation (btr_cur_t *cursor, mtr_t *mtr)
UNIV_INLINE ibool btr_cur_can_delete_without_compress (btr_cur_t *cursor, ulint rec_size, mtr_t *mtr)
UNIV_INLINE ibool btr_blob_op_is_update (enum blob_op op)

Detailed Description

The index tree cursor

Created 10/16/1994 Heikki Tuuri

Macro Definition Documentation

#define LIMIT_OPTIMISTIC_INSERT_DEBUG (   NREC,
  CODE 
)
Value:
if (btr_cur_limit_optimistic_insert_debug > 1\
&& (NREC) >= (ulint)btr_cur_limit_optimistic_insert_debug) {\
CODE;\
}

Function Documentation

UNIV_INLINE ibool btr_blob_op_is_update ( enum blob_op  op)

Determine if an operation on off-page columns is an update.

Returns
TRUE if op != BTR_STORE_INSERT
Parameters
opin: operation
UNIV_INLINE ibool btr_cur_can_delete_without_compress ( btr_cur_t cursor,
ulint  rec_size,
mtr_t mtr 
)

Checks if the record on which the cursor is placed can be deleted without making tree compression necessary (or, recommended).

Returns
TRUE if can be deleted without recommended compression
Parameters
cursorin: btr cursor
rec_sizein: rec_get_size(btr_cur_get_rec(cursor))
mtrin: mtr
UNIV_INLINE ibool btr_cur_compress_recommendation ( btr_cur_t cursor,
mtr_t mtr 
)

Checks if compressing an index page where a btr cursor is placed makes sense.

Returns
TRUE if compression is recommended
Parameters
cursorin: btr cursor
mtrin: mtr
UNIV_INLINE buf_block_t* btr_cur_get_block ( const btr_cur_t cursor)

Returns the buffer block on which the tree cursor is positioned.

Returns
pointer to buffer block
Parameters
cursorin: tree cursor
UNIV_INLINE page_t* btr_cur_get_page ( btr_cur_t cursor)

Returns the page of a tree cursor.

Returns
pointer to page
Parameters
cursorin: tree cursor
UNIV_INLINE page_cur_t* btr_cur_get_page_cur ( const btr_cur_t cursor)

Returns the page cursor component of a tree cursor.

Returns
pointer to page cursor component
Parameters
cursorin: tree cursor
UNIV_INLINE page_zip_des_t* btr_cur_get_page_zip ( btr_cur_t cursor)

Returns the compressed page on which the tree cursor is positioned.

Returns
pointer to compressed page, or NULL if the page is not compressed
Parameters
cursorin: tree cursor
UNIV_INLINE rec_t* btr_cur_get_rec ( const btr_cur_t cursor)

Returns the record pointer of a tree cursor.

Returns
pointer to record
Parameters
cursorin: tree cursor
UNIV_INLINE void btr_cur_invalidate ( btr_cur_t cursor)

Invalidates a tree cursor by setting record pointer to NULL.

Parameters
cursorin: tree cursor
UNIV_INLINE void btr_cur_position ( dict_index_t index,
rec_t *  rec,
buf_block_t block,
btr_cur_t cursor 
)

Positions a tree cursor at a given record.

Parameters
indexin: index
recin: record in tree
blockin: buffer block of rec
cursorout: cursor