MCPcopy Create free account
hub / github.com/RedisGraph/RedisGraph / DataBlock_AllocateItemOutOfOrder

Function DataBlock_AllocateItemOutOfOrder

src/util/datablock/datablock.c:236–247  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

234//------------------------------------------------------------------------------
235
236void *DataBlock_AllocateItemOutOfOrder
237(
238 DataBlock *dataBlock,
239 uint64_t idx
240) {
241 // Check if idx<=data block's current capacity. If needed, allocate additional blocks.
242 DataBlock_Ensure(dataBlock, idx);
243 DataBlockItemHeader *item_header = DataBlock_GetItemHeader(dataBlock, idx);
244 MARK_HEADER_AS_NOT_DELETED(item_header);
245 dataBlock->itemCount++;
246 return ITEM_DATA(item_header);
247}
248
249void DataBlock_MarkAsDeletedOutOfOrder
250(

Callers 3

Serializer_Graph_SetNodeFunction · 0.85
Serializer_Graph_SetEdgeFunction · 0.85

Calls 2

DataBlock_EnsureFunction · 0.85
DataBlock_GetItemHeaderFunction · 0.85

Tested by 1