Internal Bidirection Node used with XBidiCompositeSkipList. More...
#include <CSCompositeSkipList.h>
Classes | |
struct | Pointers |
Structure to store forward and backward pointers including skip amounts. More... | |
Public Types | |
typedef size_t | size_type |
An unsigned integral type that can represent any nonnegative value of the container's distance type. | |
typedef Pointers | ptr_type |
Type for skiplist pointers. | |
Public Member Functions | |
XBidiNode< T, N, S > *& | forward (unsigned int ptr_type, unsigned int level) |
Returns next node at a given level and internal container index. | |
XBidiNode< T, N, S > *& | backward (unsigned int ptr_type, unsigned int level) |
Returns previous node at a given level and internal container index. | |
size_type & | skip (unsigned int ptr_type, unsigned int level) |
Returns skip amount at a given level and internal container index. | |
XBidiNode< T, N, S > * | forward (unsigned int ptr_type, unsigned int level) const |
Returns next node at a given level and internal container index. | |
XBidiNode< T, N, S > * | backward (unsigned int ptr_type, unsigned int level) const |
Returns previous node at a given level and internal container index. | |
size_type | skip (unsigned int ptr_type, unsigned int level) const |
Returns skip amount at a given level and internal container index. | |
XBidiNode (unsigned int level, const T obj) | |
Custom Constructor. | |
XBidiNode (unsigned int level) | |
Custom Constructor. | |
unsigned int | getListCount () const |
Total number of internal containers. | |
unsigned int | getIndexCount () const |
Index of first non-indexed sorted internal container. | |
Public Attributes | |
T | object |
Object stored in this node. | |
unsigned int | level |
How many forward and backward pointer levels there are. | |
ptr_type | pointers [1] |
Levels of pointers. Extra levels allocated beyond end of node. |
Internal Bidirection Node used with XBidiCompositeSkipList.
Internal containers also use this node. DON'T LOOK!!!
T | Type of object stored as an element in the container. |
N | The total number of internal containers. |
S | The index of the first non-indexed, sorted container. |
XBidiNode< T, N, S >::XBidiNode | ( | unsigned int | level, |
const T | obj | ||
) | [inline] |
Custom Constructor.
level | Number of levels in this node. |
obj | Copy of object to store in this node. |
XBidiNode< T, N, S >::XBidiNode | ( | unsigned int | level | ) | [inline] |
Custom Constructor.
Default object element will be created in this node.
level | Number of levels in this node. |
XBidiNode<T,N,S>*& XBidiNode< T, N, S >::forward | ( | unsigned int | ptr_type, |
unsigned int | level | ||
) | [inline] |
Returns next node at a given level and internal container index.
/param ptr_type Internal container index. /param level Level requested. /returns Next node at given level in selected internal container.
XBidiNode<T,N,S>*& XBidiNode< T, N, S >::backward | ( | unsigned int | ptr_type, |
unsigned int | level | ||
) | [inline] |
Returns previous node at a given level and internal container index.
/param ptr_type Internal container index. /param level Level requested. /returns Previous node at given level in selected internal container.
size_type& XBidiNode< T, N, S >::skip | ( | unsigned int | ptr_type, |
unsigned int | level | ||
) | [inline] |
Returns skip amount at a given level and internal container index.
This gives the amount of nodes at level 0 skipped over if we go to the very next node on this level.
/param ptr_type Internal container index. /param level Level requested. /returns Forward skip amount at given level in selected internal container.
XBidiNode<T,N,S>* XBidiNode< T, N, S >::forward | ( | unsigned int | ptr_type, |
unsigned int | level | ||
) | const [inline] |
Returns next node at a given level and internal container index.
/param ptr_type Internal container index. /param level Level requested. /returns Next node at given level in selected internal container.
XBidiNode<T,N,S>* XBidiNode< T, N, S >::backward | ( | unsigned int | ptr_type, |
unsigned int | level | ||
) | const [inline] |
Returns previous node at a given level and internal container index.
/param ptr_type Internal container index. /param level Level requested. /returns Previous node at given level in selected internal container.
size_type XBidiNode< T, N, S >::skip | ( | unsigned int | ptr_type, |
unsigned int | level | ||
) | const [inline] |
Returns skip amount at a given level and internal container index.
This gives the amount of nodes at level 0 skipped over if we go to the very next node on this level.
/param ptr_type Internal container index. /param level Level requested. /returns Forward skip amount at given level in selected internal container.