libubox
C utility functions for OpenWrt.
avl_tree Struct Reference

#include <avl.h>

Collaboration diagram for avl_tree:

Data Fields

struct list_head list_head
 
struct avl_noderoot
 
unsigned int count
 
bool allow_dups
 
avl_tree_comp comp
 
void * cmp_ptr
 

Detailed Description

This struct is the central management part of an avl tree. One of them is necessary for each avl_tree.

Definition at line 110 of file avl.h.

Field Documentation

◆ allow_dups

bool avl_tree::allow_dups

true if multiple nodes with the same key are allowed in the tree, false otherwise

Definition at line 131 of file avl.h.

◆ cmp_ptr

void* avl_tree::cmp_ptr

custom pointer delivered to the tree comparator

Definition at line 144 of file avl.h.

◆ comp

avl_tree_comp avl_tree::comp

pointer to the tree comparator

First two parameters are keys to compare, third parameter is a copy of cmp_ptr

Definition at line 139 of file avl.h.

◆ count

unsigned int avl_tree::count

number of nodes in the avl tree

Definition at line 125 of file avl.h.

◆ list_head

struct list_head avl_tree::list_head

Head of linked list node for supporting easy iteration and multiple elments with the same key.

Definition at line 94 of file avl.h.

◆ root

struct avl_node* avl_tree::root

pointer to the root node of the avl tree, NULL if tree is empty

Definition at line 120 of file avl.h.


The documentation for this struct was generated from the following file: