ROSS
Data Structures | Macros | Functions
avl_tree.h File Reference
#include <ross.h>

Go to the source code of this file.

Data Structures

struct  avlNode
 

Macros

#define AVL_EMPTY   (0)
 

Functions

void avlDestroy (AvlTree t)
 
int avlGetHeight (AvlTree t)
 
int avlSearch (AvlTree t, tw_event *key)
 
void avlInsert (AvlTree *t, tw_event *key)
 
void avlSanityCheck (AvlTree t)
 
void avlPrintKeys (AvlTree t)
 
tw_eventavlDeleteMin (AvlTree *t)
 
tw_eventavlDelete (AvlTree *t, tw_event *key)
 
AvlTree avl_alloc (void)
 
void avl_free (AvlTree t)
 

Macro Definition Documentation

#define AVL_EMPTY   (0)

Function Documentation

AvlTree avl_alloc ( void  )

Definition at line 300 of file avl_tree.c.

References tw_pe::avl_list_head, g_tw_avl_node_count, g_tw_pe, avlNode::next, tw_error(), and TW_LOC.

Referenced by avlInsert().

Here is the call graph for this function:

Here is the caller graph for this function:

void avl_free ( AvlTree  t)

Definition at line 316 of file avl_tree.c.

References AVL_EMPTY, tw_pe::avl_list_head, and g_tw_pe.

Referenced by avlDelete(), avlDeleteMin(), and avlDestroy().

Here is the caller graph for this function:

tw_event* avlDelete ( AvlTree t,
tw_event key 
)

Definition at line 251 of file avl_tree.c.

References AVL_EMPTY, avl_free(), avlDelete(), avlDeleteMin(), avlRebalance(), avlNode::child, tw_event::event_id, tw_event::recv_ts, tw_event::send_pe, tw_error(), TW_LOC, and TW_STIME_CMP.

Referenced by avlDelete(), and tw_hash_remove().

Here is the call graph for this function:

Here is the caller graph for this function:

tw_event* avlDeleteMin ( AvlTree t)

Definition at line 226 of file avl_tree.c.

References AVL_EMPTY, avl_free(), avlDeleteMin(), avlRebalance(), avlNode::child, and avlNode::key.

Referenced by avlDelete(), and avlDeleteMin().

Here is the call graph for this function:

Here is the caller graph for this function:

void avlDestroy ( AvlTree  t)

Definition at line 15 of file avl_tree.c.

References AVL_EMPTY, avl_free(), avlDestroy(), and avlNode::child.

Referenced by avlDestroy().

Here is the call graph for this function:

Here is the caller graph for this function:

int avlGetHeight ( AvlTree  t)

Definition at line 28 of file avl_tree.c.

References AVL_EMPTY, and avlNode::height.

Referenced by avlFixHeight(), avlRebalance(), and avlSanityCheck().

Here is the caller graph for this function:

void avlInsert ( AvlTree t,
tw_event key 
)

Definition at line 163 of file avl_tree.c.

References avl_alloc(), AVL_EMPTY, avlInsert(), avlRebalance(), tw_event::event_id, g_tw_avl_node_count, tw_event::recv_ts, tw_event::send_pe, tw_error(), TW_LOC, tw_printf(), and TW_STIME_CMP.

Referenced by avlInsert(), and tw_hash_insert().

Here is the call graph for this function:

Here is the caller graph for this function:

void avlPrintKeys ( AvlTree  t)

Definition at line 214 of file avl_tree.c.

References AVL_EMPTY, avlPrintKeys(), and avlNode::child.

Referenced by avlPrintKeys().

Here is the call graph for this function:

Here is the caller graph for this function:

void avlSanityCheck ( AvlTree  t)

Definition at line 72 of file avl_tree.c.

References AVL_EMPTY, avlGetHeight(), avlSanityCheck(), avlNode::child, avlNode::height, and ROSS_MAX.

Referenced by avlSanityCheck().

Here is the call graph for this function:

Here is the caller graph for this function:

int avlSearch ( AvlTree  t,
tw_event key 
)

Definition at line 40 of file avl_tree.c.

References AVL_EMPTY, avlSearch(), avlNode::child, tw_event::event_id, avlNode::key, tw_event::recv_ts, tw_event::send_pe, and TW_STIME_CMP.

Referenced by avlSearch().

Here is the call graph for this function:

Here is the caller graph for this function: