MCPcopy Create free account
hub / github.com/FirebirdSQL/firebird / readJumpNode

Method readJumpNode

src/jrd/btn.cpp:303–342  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

301
302
303UCHAR* IndexJumpNode::readJumpNode(UCHAR* pagePointer)
304{
305/**************************************
306 *
307 * r e a d J u m p N o d e
308 *
309 **************************************
310 *
311 * Functional description
312 * Read a jump node from the page by the
313 * given pagePointer and the return the
314 * remaining position after the read.
315 *
316 **************************************/
317 nodePointer = pagePointer;
318
319 // Get prefix
320 UCHAR tmp = *pagePointer++;
321 prefix = (tmp & 0x7F);
322 if (tmp & 0x80)
323 {
324 tmp = *pagePointer++;
325 prefix |= (tmp & 0x7F) << 7; // We get 14 bits at this point
326 }
327
328 // Get length
329 tmp = *pagePointer++;
330 length = (tmp & 0x7F);
331 if (tmp & 0x80)
332 {
333 tmp = *pagePointer++;
334 length |= (tmp & 0x7F) << 7; // We get 14 bits at this point
335 }
336
337 offset = get_short(pagePointer);
338 pagePointer += sizeof(USHORT);
339 data = pagePointer;
340 pagePointer += length;
341 return pagePointer;
342}
343
344
345UCHAR* IndexJumpNode::writeJumpNode(UCHAR* pagePointer)

Callers 5

walk_indexMethod · 0.80
delete_nodeFunction · 0.80
find_area_start_pointFunction · 0.80
garbage_collectFunction · 0.80
insert_nodeFunction · 0.80

Calls 1

get_shortFunction · 0.85

Tested by

no test coverage detected