diff options
Diffstat (limited to 'storage/innobase/include/btr0pcur.ic')
-rw-r--r-- | storage/innobase/include/btr0pcur.ic | 54 |
1 files changed, 27 insertions, 27 deletions
diff --git a/storage/innobase/include/btr0pcur.ic b/storage/innobase/include/btr0pcur.ic index 9a7d7867025..a8aa82cf203 100644 --- a/storage/innobase/include/btr0pcur.ic +++ b/storage/innobase/include/btr0pcur.ic @@ -102,7 +102,7 @@ btr_pcur_get_rec( { ut_ad(cursor->pos_state == BTR_PCUR_IS_POSITIONED); ut_ad(cursor->latch_mode != BTR_NO_LATCHES); - + return(page_cur_get_rec(btr_pcur_get_page_cur(cursor))); } @@ -152,7 +152,7 @@ btr_pcur_get_low_match( } /************************************************************* -Checks if the persistent cursor is after the last user record on +Checks if the persistent cursor is after the last user record on a page. */ UNIV_INLINE ibool @@ -164,12 +164,12 @@ btr_pcur_is_after_last_on_page( UT_NOT_USED(mtr); ut_ad(cursor->pos_state == BTR_PCUR_IS_POSITIONED); ut_ad(cursor->latch_mode != BTR_NO_LATCHES); - + return(page_cur_is_after_last(btr_pcur_get_page_cur(cursor))); } /************************************************************* -Checks if the persistent cursor is before the first user record on +Checks if the persistent cursor is before the first user record on a page. */ UNIV_INLINE ibool @@ -181,7 +181,7 @@ btr_pcur_is_before_first_on_page( UT_NOT_USED(mtr); ut_ad(cursor->pos_state == BTR_PCUR_IS_POSITIONED); ut_ad(cursor->latch_mode != BTR_NO_LATCHES); - + return(page_cur_is_before_first(btr_pcur_get_page_cur(cursor))); } @@ -196,9 +196,9 @@ btr_pcur_is_on_user_rec( { ut_ad(cursor->pos_state == BTR_PCUR_IS_POSITIONED); ut_ad(cursor->latch_mode != BTR_NO_LATCHES); - + if ((btr_pcur_is_before_first_on_page(cursor, mtr)) - || (btr_pcur_is_after_last_on_page(cursor, mtr))) { + || (btr_pcur_is_after_last_on_page(cursor, mtr))) { return(FALSE); } @@ -218,7 +218,7 @@ btr_pcur_is_before_first_in_tree( { ut_ad(cursor->pos_state == BTR_PCUR_IS_POSITIONED); ut_ad(cursor->latch_mode != BTR_NO_LATCHES); - + if (btr_page_get_prev(btr_pcur_get_page(cursor), mtr) != FIL_NULL) { return(FALSE); @@ -239,7 +239,7 @@ btr_pcur_is_after_last_in_tree( { ut_ad(cursor->pos_state == BTR_PCUR_IS_POSITIONED); ut_ad(cursor->latch_mode != BTR_NO_LATCHES); - + if (btr_page_get_next(btr_pcur_get_page(cursor), mtr) != FIL_NULL) { return(FALSE); @@ -260,7 +260,7 @@ btr_pcur_move_to_next_on_page( UT_NOT_USED(mtr); ut_ad(cursor->pos_state == BTR_PCUR_IS_POSITIONED); ut_ad(cursor->latch_mode != BTR_NO_LATCHES); - + page_cur_move_to_next(btr_pcur_get_page_cur(cursor)); cursor->old_stored = BTR_PCUR_OLD_NOT_STORED; @@ -278,7 +278,7 @@ btr_pcur_move_to_prev_on_page( UT_NOT_USED(mtr); ut_ad(cursor->pos_state == BTR_PCUR_IS_POSITIONED); ut_ad(cursor->latch_mode != BTR_NO_LATCHES); - + page_cur_move_to_prev(btr_pcur_get_page_cur(cursor)); cursor->old_stored = BTR_PCUR_OLD_NOT_STORED; @@ -295,7 +295,7 @@ btr_pcur_move_to_last_on_page( { UT_NOT_USED(mtr); ut_ad(cursor->latch_mode != BTR_NO_LATCHES); - + page_cur_set_after_last(buf_frame_align(btr_pcur_get_rec(cursor)), btr_pcur_get_page_cur(cursor)); @@ -356,14 +356,14 @@ btr_pcur_move_to_next( ut_ad(cursor->latch_mode != BTR_NO_LATCHES); cursor->old_stored = BTR_PCUR_OLD_NOT_STORED; - + if (btr_pcur_is_after_last_on_page(cursor, mtr)) { if (btr_pcur_is_after_last_in_tree(cursor, mtr)) { return(FALSE); } - + btr_pcur_move_to_next_page(cursor, mtr); return(TRUE); @@ -371,7 +371,7 @@ btr_pcur_move_to_next( btr_pcur_move_to_next_on_page(cursor, mtr); - return(TRUE); + return(TRUE); } /****************************************************************** @@ -388,12 +388,12 @@ btr_pcur_commit( { ut_a(pcur->pos_state == BTR_PCUR_IS_POSITIONED); - pcur->latch_mode = BTR_NO_LATCHES; + pcur->latch_mode = BTR_NO_LATCHES; mtr_commit(pcur->mtr); pcur->pos_state = BTR_PCUR_WAS_POSITIONED; -} +} /****************************************************************** Differs from btr_pcur_commit in that we can specify the mtr to commit. */ @@ -406,12 +406,12 @@ btr_pcur_commit_specify_mtr( { ut_a(pcur->pos_state == BTR_PCUR_IS_POSITIONED); - pcur->latch_mode = BTR_NO_LATCHES; + pcur->latch_mode = BTR_NO_LATCHES; mtr_commit(mtr); pcur->pos_state = BTR_PCUR_WAS_POSITIONED; -} +} /****************************************************************** Sets the pcur latch mode to BTR_NO_LATCHES. */ @@ -422,7 +422,7 @@ btr_pcur_detach( btr_pcur_t* pcur) /* in: persistent cursor */ { ut_a(pcur->pos_state == BTR_PCUR_IS_POSITIONED); - + pcur->latch_mode = BTR_NO_LATCHES; pcur->pos_state = BTR_PCUR_WAS_POSITIONED; @@ -440,7 +440,7 @@ btr_pcur_is_detached( if (pcur->latch_mode == BTR_NO_LATCHES) { return(TRUE); - } + } return(FALSE); } @@ -452,7 +452,7 @@ void btr_pcur_init( /*==========*/ btr_pcur_t* pcur) /* in: persistent cursor */ -{ +{ pcur->old_stored = BTR_PCUR_OLD_NOT_STORED; pcur->old_rec_buf = NULL; pcur->old_rec = NULL; @@ -485,7 +485,7 @@ btr_pcur_open( cursor->latch_mode = latch_mode; cursor->search_mode = mode; - + /* Search with the tree cursor */ btr_cursor = btr_pcur_get_btr_cur(cursor); @@ -527,7 +527,7 @@ btr_pcur_open_with_no_init( cursor->latch_mode = latch_mode; cursor->search_mode = mode; - + /* Search with the tree cursor */ btr_cursor = btr_pcur_get_btr_cur(cursor); @@ -591,7 +591,7 @@ btr_pcur_open_at_rnd_pos( cursor->latch_mode = latch_mode; cursor->search_mode = PAGE_CUR_G; - + btr_pcur_init(cursor); btr_cur_open_at_rnd_pos(index, latch_mode, @@ -601,7 +601,7 @@ btr_pcur_open_at_rnd_pos( cursor->trx_if_known = NULL; } - + /****************************************************************** Frees the possible memory heap of a persistent cursor and sets the latch mode of the persistent cursor to BTR_NO_LATCHES. */ @@ -622,7 +622,7 @@ btr_pcur_close( cursor->btr_cur.page_cur.rec = NULL; cursor->old_rec = NULL; cursor->old_stored = BTR_PCUR_OLD_NOT_STORED; - + cursor->latch_mode = BTR_NO_LATCHES; cursor->pos_state = BTR_PCUR_NOT_POSITIONED; |