Turnstone Operating System
Loading...
Searching...
No Matches
rbtree.h File Reference

tosdb internal interface More...

#include <indexer.h>

Macros

#define ___RBLTREE_H   0
 
#define rbtree_create_index(c)   rbtree_create_index_with_heap(NULL, c)
 

Functions

index_trbtree_create_index_with_heap (memory_heap_t *heap, index_key_comparator_f comparator)
 create rbtree index More...
 
int8_t rbtree_destroy_index (index_t *idx)
 destroy rbtree index More...
 

Detailed Description

tosdb internal interface

This work is licensed under TURNSTONE OS Public License. Please read and understand latest version of Licence.

Macro Definition Documentation

◆ ___RBLTREE_H

#define ___RBLTREE_H   0

macro for preventing second time include

◆ rbtree_create_index

#define rbtree_create_index (   c)    rbtree_create_index_with_heap(NULL, c)

macro for creating rbtree index with default heap

Function Documentation

◆ rbtree_create_index_with_heap()

index_t * rbtree_create_index_with_heap ( memory_heap_t heap,
index_key_comparator_f  comparator 
)

create rbtree index

Parameters
[in]heapmemory heap to use
[in]comparatorindex key comparator
Returns
index or null

◆ rbtree_destroy_index()

int8_t rbtree_destroy_index ( index_t idx)

destroy rbtree index

Parameters
[in]idxindex to destroy
Returns
0 if success