Doubly-Linked List Utility Functions
The doubly-linked list utility functions provide common routines for managing linked lists. More...Classes | |
| struct | OSRTScalarDListNode |
| This structure is used to hold a single data item within the list. More... | |
| struct | OSRTScalarDList |
| This is the main list structure. More... | |
| struct | OSRTScalarDListNode |
| This structure is used to hold a single data item within the list. More... | |
| struct | OSRTScalarDList |
| This is the main list structure. More... | |
Functions | |
| EXTERNRT void | rtxScalarDListInit (OSRTScalarDList *pList) |
| This function initializes a doubly linked list structure. | |
| EXTERNRT OSRTScalarDListNode * | rtxScalarDListAppendDouble (struct OSCTXT *pctxt, OSRTScalarDList *pList, OSDOUBLE value) |
| This set of functions appends an item of the given scalar type to the linked list structure. | |
| EXTERNRT OSRTScalarDListNode * | rtxScalarDListAppendNode (OSRTScalarDList *pList, OSRTScalarDListNode *pListNode) |
| This function is used to append a node to the linked list. | |
| EXTERNRT OSRTScalarDListNode * | rtxScalarDListInsertNode (OSRTScalarDList *pList, OSUINT32 index, OSRTScalarDListNode *pListNode) |
| This function is used to insert a node into the linked list. | |
| EXTERNRT OSRTScalarDListNode * | rtxScalarDListFindByIndex (const OSRTScalarDList *pList, OSUINT32 index) |
| This function will return the node pointer of the indexed entry in the list. | |
| EXTERNRT void | rtxScalarDListFreeNode (struct OSCTXT *pctxt, OSRTScalarDList *pList, OSRTScalarDListNode *node) |
| This function will remove the given node from the list and free memory. | |
| EXTERNRT void | rtxScalarDListRemove (OSRTScalarDList *pList, OSRTScalarDListNode *node) |
| This function will remove the given node from the list. | |
| EXTERNRT void | rtxScalarDListFreeNodes (struct OSCTXT *pctxt, OSRTScalarDList *pList) |
| This function will free all of the dynamic memory used to hold the list node pointers. | |
Detailed Description
The doubly-linked list utility functions provide common routines for managing linked lists.This module is identical to the rtxDList module except that the data varaibles that can be added to the lists are scalars (integer, double, float, etc.) whereas the standard rtxDList type hold pointers to more complex data items.
Function Documentation
|
||||||||||||||||
|
This set of functions appends an item of the given scalar type to the linked list structure. Separate functions exist for all of the different supported scalar types.
|
|
||||||||||||
|
This function is used to append a node to the linked list. This can be used instead of a scalar value append function. It requires the user to allocate and populate the list node structure.
|
|
||||||||||||
|
This function will return the node pointer of the indexed entry in the list.
|
|
||||||||||||||||
|
This function will remove the given node from the list and free memory.
It is assumed that memory for the list node structure was allocated using the
|
|
||||||||||||
|
This function will free all of the dynamic memory used to hold the list node pointers.
|
|
|
This function initializes a doubly linked list structure.
It sets the number of elements to zero and sets all internal pointer values to NULL. A doubly-linked scalar list structure is described by the
|
|
||||||||||||||||
|
This function is used to insert a node into the linked list.
|
|
||||||||||||
|
This function will remove the given node from the list.
|
