source: trunk/src/win32k/include/avl.h@ 1467

Last change on this file since 1467 was 1467, checked in by bird, 26 years ago

Corrections to make win32k work.
(And now it does work, at least at my test machine...)

File size: 1.1 KB
Line 
1/* $Id: avl.h,v 1.1 1999-10-27 02:02:55 bird Exp $
2 *
3 * AVL-Tree (lookalike) declaration.
4 *
5 * Copyright (c) 1999 knut st. osmundsen
6 *
7 * Project Odin Software License can be found in LICENSE.TXT
8 *
9 */
10#ifndef _AVL_H_
11#define _AVL_H_
12
13#ifdef __cplusplus
14extern "C" {
15#endif
16
17/**
18 * AVL key type
19 */
20typedef unsigned long AVLKEY;
21
22/**
23 * AVL Core node.
24 */
25typedef struct _AVLNodeCore
26{
27 unsigned char uchHeight; /* Height of this tree: max(heigth(left), heigth(right)) + 1 */
28 struct _AVLNodeCore * pLeft; /* Pointer to left leaf node. */
29 struct _AVLNodeCore * pRight; /* Pointer to right leaf node. */
30 AVLKEY Key; /* Key value. */
31} AVLNODECORE, *PAVLNODECORE, **PPAVLNODECORE;
32
33
34void AVLInsert(PPAVLNODECORE ppTree, PAVLNODECORE pNode);
35PAVLNODECORE AVLRemove(PPAVLNODECORE ppTree, AVLKEY Key);
36PAVLNODECORE AVLGet(PPAVLNODECORE ppTree, AVLKEY Key);
37PAVLNODECORE AVLGetWithAdjecentNodes(PPAVLNODECORE ppTree, AVLKEY Key, PPAVLNODECORE ppLeft, PPAVLNODECORE ppRight);
38
39
40/*
41 * Just in case NULL is undefined.
42 */
43#ifndef NULL
44 #define NULL ((void*)0)
45#endif
46
47#ifdef __cplusplus
48}
49#endif
50
51#endif
Note: See TracBrowser for help on using the repository browser.