Struct bstree_params

Struct Documentation

struct bstree_params

Parameters for bstree.

Public Members

int (*cmpkey)(const void *const e1, const void *const e2)

For comparing keys associated with elements. Cannot be NULL.

void (*printe)(const void *e)

For printing an element. Can be NULL.

dptr_t *meta

Pointer to application-allocated space for storing the bstree nodes. Ignored unless RCSW_NOALLOC_META is passed.

dptr_t *elements

Pointer to application-allocated space for storing data managed by the bstree. Ignored unless RCSW_NOALLOC_DATA is passed.

size_t elt_size

Size of elements in bytes.

int max_elts

Maximum number of elements allowed. -1 = no upper limit.

uint32_t flags

Configuration flags. See bstree::flags for valid flags.