Lines Matching full:item
12 * copy copy_count entries from source directory item to dest buffer
13 * (creating new item if needed)
21 * either the number of target item, or if we must create a in leaf_copy_dir_entries()
22 * new item, the number of the item we will create it next to in leaf_copy_dir_entries()
28 int copy_records_len; /* length of all records in item to be copied */ in leaf_copy_dir_entries()
33 RFALSE(!is_direntry_le_ih(ih), "vs-10000: item must be directory item"); in leaf_copy_dir_entries()
59 * if there are no items in dest or the first/last item in in leaf_copy_dir_entries()
60 * dest is not item of the same directory in leaf_copy_dir_entries()
69 /* create new item in dest */ in leaf_copy_dir_entries()
72 /* form item header */ in leaf_copy_dir_entries()
75 /* calculate item len */ in leaf_copy_dir_entries()
88 * item in this function in leaf_copy_dir_entries()
92 * this item is not yet valid, but we in leaf_copy_dir_entries()
101 /* insert item into dest buffer */ in leaf_copy_dir_entries()
129 * (last_first == LAST_TO_FIRST) item or part of it or nothing
147 * if ( DEST is empty or first item of SOURCE and last item of in leaf_copy_boundary_item()
149 * then there is no need to treat this item differently from the in leaf_copy_boundary_item()
162 "vs-10010: item can not have empty length"); in leaf_copy_boundary_item()
174 * copy part of the body of the first item of SOURCE in leaf_copy_boundary_item()
175 * to the end of the body of the last item of the DEST in leaf_copy_boundary_item()
177 * == -1 copy whole body; don't create new item header in leaf_copy_boundary_item()
196 * merge first item (or its part) of src buffer with the last in leaf_copy_boundary_item()
197 * item of dest buffer. Both are of the same file in leaf_copy_boundary_item()
205 …"vs-10030: merge to left: last unformatted node of non-last indirect item %h must have zerto free … in leaf_copy_boundary_item()
214 /* copy boundary item to right (last_first == LAST_TO_FIRST) */ in leaf_copy_boundary_item()
217 * (DEST is empty or last item of SOURCE and first item of DEST in leaf_copy_boundary_item()
230 * item body of SOURCE in leaf_copy_boundary_item()
243 * copy part of the body of the last item of SOURCE to the in leaf_copy_boundary_item()
244 * begin of the body of the first item of the DEST; part defined in leaf_copy_boundary_item()
246 * change first item key of the DEST; don't create new item header in leaf_copy_boundary_item()
250 …"vs-10040: merge to right: last unformatted node of non-last indirect item must be filled entirely… in leaf_copy_boundary_item()
254 /* bytes_or_entries = length of last item body of SOURCE */ in leaf_copy_boundary_item()
261 /* change first item key of the DEST */ in leaf_copy_boundary_item()
264 /* item becomes non-mergeable */ in leaf_copy_boundary_item()
265 /* or mergeable if left item was */ in leaf_copy_boundary_item()
268 /* merge to right only part of item */ in leaf_copy_boundary_item()
274 /* change first item key of the DEST */ in leaf_copy_boundary_item()
306 * from first-th item in src to tail of dest
308 * from first-th item in src to head of dest
342 * we will insert items before 0-th or nr-th item in dest buffer. in leaf_copy_items_entirely()
347 /* location of head of first new item */ in leaf_copy_items_entirely()
357 /* copy item headers */ in leaf_copy_items_entirely()
363 /* location of unmovable item */ in leaf_copy_items_entirely()
388 /* sizes, item number */ in leaf_copy_items_entirely()
411 * This function splits the (liquid) item into two items (useful when
412 * shifting part of an item into another node.)
422 "vs-10170: bytes == - 1 means: do not split item"); in leaf_item_bottle()
426 * if ( if item in position item_num in buffer SOURCE in leaf_item_bottle()
427 * is directory item ) in leaf_item_bottle()
437 * copy part of the body of the item number 'item_num' in leaf_item_bottle()
439 * 'cpy_bytes'; create new item header; change old in leaf_item_bottle()
447 …"vs-10180: when whole indirect item is bottle to left neighbor, it must have free_space==0 (not %l… in leaf_item_bottle()
453 "vs-10190: bad mergeability of item %h", ih); in leaf_item_bottle()
460 * if ( if item in position item_num in buffer in leaf_item_bottle()
461 * SOURCE is directory item ) in leaf_item_bottle()
473 * copy part of the body of the item number 'item_num' in leaf_item_bottle()
475 * 'cpy_bytes'; create new item header; in leaf_item_bottle()
490 /* indirect item */ in leaf_item_bottle()
492 "vs-10200: ih->ih_free_space must be 0 when indirect item will be appended"); in leaf_item_bottle()
502 /* set item length */ in leaf_item_bottle()
518 * items from SOURCE to DEST. From last item copy cpy_num bytes for regular
519 * item and cpy_num directory entries for directory item.
548 * copy the first item or it part or nothing to the end of in leaf_copy_items()
572 * copy part of the item which number is in leaf_copy_items()
587 * copy the last item or it part or nothing to the in leaf_copy_items()
614 * copy part of the item which number is pos to in leaf_copy_items()
712 * copy mov_num items and mov_bytes of the (mov_num-1)th item to
738 * Shift shift_num items (and shift_bytes of last shifted item if
781 "vs-10280: item must be mergeable"); in leaf_shift_left()
821 * items in whole. Delete part of body of the first item. Part defined by
822 * del_bytes. Don't delete first item header
824 * items in whole. Delete part of body of the last item . Part defined by
825 * del_bytes. Don't delete last item header.
838 "10165: invalid number of first item to be deleted (%d) or " in leaf_delete_items()
852 /* delete del_num items beginning from item in position first */ in leaf_delete_items()
858 * item in position first in leaf_delete_items()
863 * delete the part of the first item of the bh in leaf_delete_items()
864 * do not delete item header in leaf_delete_items()
873 * item in position first+1 in leaf_delete_items()
880 /* the last item is directory */ in leaf_delete_items()
883 * in this item in leaf_delete_items()
887 /* len = body len of item */ in leaf_delete_items()
891 * delete the part of the last item of the bh in leaf_delete_items()
892 * do not delete item header in leaf_delete_items()
900 /* insert item into the leaf node in position before */
920 "vs-10170: not enough free space in block %z, new item %h", in leaf_insert_into_buf()
923 "vs-10172: zero number == %d, item length == %d", in leaf_insert_into_buf()
926 /* get item new item must be inserted before */ in leaf_insert_into_buf()
929 /* prepare space for the body of new item */ in leaf_insert_into_buf()
947 /* insert item header */ in leaf_insert_into_buf()
957 /* sizes, free space, item number */ in leaf_insert_into_buf()
975 * paste paste_size bytes to affected_item_num-th item.
976 * When item is a directory, this only prepare space for new entries
1010 /* item to be appended */ in leaf_paste_in_buffer()
1034 /* paste data in the head of item */ in leaf_paste_in_buffer()
1067 * cuts DEL_COUNT entries beginning from FROM-th entry. Directory item
1069 * necessary. Return value is size of removed part of directory item
1075 char *item; in leaf_cut_entries() local
1083 * make sure that item is directory and there are enough entries to in leaf_cut_entries()
1086 RFALSE(!is_direntry_le_ih(ih), "10180: item is not directory item"); in leaf_cut_entries()
1088 "10185: item contains not enough entries: entry_count = %d, from = %d, to delete = %d", in leaf_cut_entries()
1094 /* first byte of item */ in leaf_cut_entries()
1095 item = bh->b_data + ih_location(ih); in leaf_cut_entries()
1108 prev_record = item + prev_record_offset; in leaf_cut_entries()
1131 prev_record, item + ih_item_len(ih) - prev_record); in leaf_cut_entries()
1137 * when cut item is part of regular file
1141 * when cut item is part of directory
1158 /* item head of truncated item */ in leaf_cut_from_buffer()
1167 "when 0-th enrty of item is cut, that item must be first in the node, not %d-th", in leaf_cut_from_buffer()
1169 /* change item key by key of first entry in the item */ in leaf_cut_from_buffer()
1173 /* item is direct or indirect */ in leaf_cut_from_buffer()
1174 RFALSE(is_statdata_le_ih(ih), "10195: item is stat data"); in leaf_cut_from_buffer()
1180 /* shift item body to left if cut is from the head of item */ in leaf_cut_from_buffer()
1186 /* change key of item */ in leaf_cut_from_buffer()
1203 /* location of the last item */ in leaf_cut_from_buffer()
1206 /* location of the item, which is remaining at the same place */ in leaf_cut_from_buffer()
1213 /* change item length */ in leaf_cut_from_buffer()
1239 /* delete del_num items from buffer starting from the first'th item */
1273 /* location of unmovable item */ in leaf_delete_items_entirely()
1283 /* delete item headers */ in leaf_delete_items_entirely()
1286 /* change item location */ in leaf_delete_items_entirely()
1292 /* sizes, item number */ in leaf_delete_items_entirely()
1312 * before to item_num-th item
1322 char *item; in leaf_paste_entries() local
1334 * make sure, that item is directory, and there are enough in leaf_paste_entries()
1337 RFALSE(!is_direntry_le_ih(ih), "10225: item is not directory item"); in leaf_paste_entries()
1342 /* first byte of dest item */ in leaf_paste_entries()
1343 item = bh->b_data + ih_location(ih); in leaf_paste_entries()
1350 item + in leaf_paste_entries()
1369 item + (ih_item_len(ih) - paste_size) - insert_point); in leaf_paste_entries()
1391 item)); in leaf_paste_entries()
1394 /* change item key if necessary (when we paste before 0-th entry */ in leaf_paste_entries()
1412 "directory item (%h) " in leaf_paste_entries()
1418 "directory item (%h) " in leaf_paste_entries()