Rev 2461 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
| Rev 2461 | Rev 2466 | ||
|---|---|---|---|
| Line 75... | Line 75... | ||
| 75 | 75 | ||
| 76 | /** Nodes key. */ |
76 | /** Nodes key. */ |
| 77 | uint64_t key; |
77 | uint64_t key; |
| 78 | 78 | ||
| 79 | /** Difference between heights of left and right subtree of this node.*/ |
79 | /** Difference between heights of left and right subtree of this node.*/ |
| 80 | short balance; |
80 | int8_t balance; |
| 81 | }; |
81 | }; |
| 82 | 82 | ||
| 83 | /** AVL tree structure. */ |
83 | /** AVL tree structure. */ |
| 84 | struct avltree |
84 | struct avltree |
| 85 | { |
85 | { |
| Line 92... | Line 92... | ||
| 92 | * |
92 | * |
| 93 | * Base is added to current key when new node is inserted into tree. |
93 | * Base is added to current key when new node is inserted into tree. |
| 94 | * Base is changed to the key of node which is deleted with function |
94 | * Base is changed to the key of node which is deleted with function |
| 95 | * avltree_delete_min. |
95 | * avltree_delete_min. |
| 96 | */ |
96 | */ |
| 97 | uint64_t base; /**< POZOR: Base time for inserting new nodes */ |
97 | uint64_t base; |
| 98 | }; |
98 | }; |
| 99 | 99 | ||
| 100 | 100 | ||
| 101 | /** Create empty AVL tree. |
101 | /** Create empty AVL tree. |
| 102 | * |
102 | * |