rtxDList.h File Reference
Doubly-Linked List Utility Functions. More...
#include "rtxsrc/osSysTypes.h"
#include "rtxsrc/rtxExternDefs.h"
#include "rtxsrc/rtxCommonDefs.h"
Go to the source code of this file.
Classes | |
struct | OSRTDListNode |
This structure is used to hold a single data item within the list. More... | |
struct | OSRTDList |
This is the main list structure. More... | |
struct | OSRTDListBuf |
struct | OSRTDListUTF8StrNode |
Defines | |
#define | DLISTBUF_SEG 16 |
#define | OSRTDLISTNODESIZE ((sizeof(OSRTDListNode)+7)&(~7)) |
#define | rtxDListAllocNodeAndData(pctxt, type, ppnode, ppdata) |
#define | rtxDListAppendData(pctxt, pList, pData) |
#define | rtxDListFastInit(pList) |
#define | rtxDListFreeTailNode(pctxt, pList) rtxDListFreeNode(pctxt,pList,(pList)->tail) |
#define | rtxDListFreeHeadNode(pctxt, pList) rtxDListFreeNode(pctxt,pList,(pList)->head) |
Typedefs | |
typedef int(*) | PEqualsFunc (const void *a, const void *b, const void *sortCtxt) |
Functions | |
EXTERNRT void | rtxDListInit (OSRTDList *pList) |
This function initializes a doubly linked list structure. | |
EXTERNRT OSRTDListNode * | rtxDListAppend (struct OSCTXT *pctxt, OSRTDList *pList, void *pData) |
This function appends an item to the linked list structure. | |
EXTERNRT OSRTDListNode * | rtxDListInsert (struct OSCTXT *pctxt, OSRTDList *pList, OSUINT32 index, void *pData) |
This function inserts an item into the linked list structure. | |
EXTERNRT OSRTDListNode * | rtxDListInsertBefore (struct OSCTXT *pctxt, OSRTDList *pList, OSRTDListNode *node, void *pData) |
This function inserts an item into the linked list structure before the specified element. | |
EXTERNRT OSRTDListNode * | rtxDListInsertAfter (struct OSCTXT *pctxt, OSRTDList *pList, OSRTDListNode *node, void *pData) |
This function inserts an item into the linked list structure after the specified element. | |
EXTERNRT OSRTDListNode * | rtxDListFindByIndex (const OSRTDList *pList, OSUINT32 index) |
This function will return the node pointer of the indexed entry in the list. | |
EXTERNRT OSRTDListNode * | rtxDListFindByData (const OSRTDList *pList, void *data) |
This function will return the node pointer of the given data item within the list or NULL if the item is not found. | |
EXTERNRT int | rtxDListFindIndexByData (const OSRTDList *pList, void *data) |
This function will return the index of the given data item within the list or -1 if the item is not found. | |
EXTERNRT void | rtxDListFreeNode (struct OSCTXT *pctxt, OSRTDList *pList, OSRTDListNode *node) |
This function will remove the given node from the list and free memory. | |
EXTERNRT void | rtxDListRemove (OSRTDList *pList, OSRTDListNode *node) |
This function will remove the given node from the list. | |
EXTERNRT void | rtxDListFreeNodes (struct OSCTXT *pctxt, OSRTDList *pList) |
This function will free all of the dynamic memory used to hold the list node pointers. | |
EXTERNRT void | rtxDListFreeAll (struct OSCTXT *pctxt, OSRTDList *pList) |
This function will free all of the dynamic memory used to hold the list node pointers and the data items. | |
EXTERNRT int | rtxDListToArray (struct OSCTXT *pctxt, OSRTDList *pList, void **ppArray, OSUINT32 *pElemCount, size_t elemSize) |
This function converts a doubly linked list to an array. | |
EXTERNRT int | rtxDListAppendArray (struct OSCTXT *pctxt, OSRTDList *pList, void *pArray, OSUINT32 numElements, size_t elemSize) |
This function appends pointers to items in the given array to a doubly linked list structure. | |
EXTERNRT int | rtxDListAppendArrayCopy (struct OSCTXT *pctxt, OSRTDList *pList, const void *pArray, OSUINT32 numElements, size_t elemSize) |
This function appends a copy of each item in the given array to a doubly linked list structure. | |
EXTERNRT int | rtxDListToUTF8Str (struct OSCTXT *pctxt, OSRTDList *pList, OSUTF8CHAR **ppstr, char sep) |
This function concatanates all of the components in the given list to form a UTF-8 string. |
Detailed Description
Doubly-Linked List Utility Functions.
Definition in file rtxDList.h.