Collaboration diagram for Linked List:
|
Files | |
| file | psList.h |
| Support for doubly linked lists. | |
Data Structures | |
| struct | psListElem |
| Doubly-linked list element. More... | |
| struct | psList |
| The psList Linked list structure. More... | |
| struct | psListIterator |
| The psList iterator structure. More... | |
Typedefs | |
| typedef psListElem | psListElem |
| Doubly-linked list element. | |
Enumerations | |
| enum | { PS_LIST_HEAD = 0, PS_LIST_TAIL = -1 } |
| Special values of index into list. More... | |
Functions | |
| psList * | psListAlloc (psPtr data) |
| Creates a psList linked list object. | |
| psListIterator * | psListIteratorAlloc (psList *list, int location, bool mutable) |
| Creates a psListIterator object and associates it with a psList. | |
| psBool | psListIteratorSet (psListIterator *iterator, int location) |
| Set the iterator of the list to a given position. | |
| psBool | psListAdd (psList *list, psS32 location, psPtr data) |
| Adds an element to a psList at position given. | |
| psBool | psListAddAfter (psListIterator *list, psPtr data) |
| Adds an data item to a psList at position just after the list position given. | |
| psBool | psListAddBefore (psListIterator *list, psPtr data) |
| Adds an data item to a psList at position just before the list position given. | |
| psBool | psListRemove (psList *list, psS32 location) |
| Remove an item at the specified location from a list. | |
| psBool | psListRemoveData (psList *list, psPtr data) |
| Remove an item from a list. | |
| psPtr | psListGet (psList *list, psS32 location) |
| Retrieve an item from a list. | |
| psPtr | psListGetAndIncrement (psListIterator *iterator) |
| Position the specified iterator to the next item in list. | |
| psPtr | psListGetAndDecrement (psListIterator *iterator) |
| Position the specified iterator to the previous item in list. | |
| psArray * | psListToArray (psList *dlist) |
| Convert a linked list to an array. | |
| psList * | psArrayToList (psArray *arr) |
| Convert array to a doubly-linked list. | |
| psList * | psListSort (psList *list, psComparePtrFcn compare) |
| Sort a list via a comparison function. | |
|
|
Doubly-linked list element.
|
|
|
Special values of index into list. This list of possible list position values should be contiguous non-positive values ending with PS_LIST_UNKNOWN. Any value less-than-or-equal-to PS_LIST_UNKNOWN is considered a undefined position. |
|
|
Convert array to a doubly-linked list.
|
|
||||||||||||||||
|
Adds an element to a psList at position given.
|
|
||||||||||||
|
Adds an data item to a psList at position just after the list position given.
|
|
||||||||||||
|
Adds an data item to a psList at position just before the list position given.
|
|
|
Creates a psList linked list object.
|
|
||||||||||||
|
Retrieve an item from a list.
|
|
|
Position the specified iterator to the previous item in list.
|
|
|
Position the specified iterator to the next item in list.
|
|
||||||||||||||||
|
Creates a psListIterator object and associates it with a psList.
|
|
||||||||||||
|
Set the iterator of the list to a given position. If location is invalid the iterator position is not changed.
|
|
||||||||||||
|
Remove an item at the specified location from a list.
|
|
||||||||||||
|
Remove an item from a list.
|
|
||||||||||||
|
Sort a list via a comparison function. The comparison function must return an integer less than, equal to, or greater than zero if the first argument is considered to be respectively less than, equal to, or greater than the second. If two members compare as equal, their order in the sorted array is undefined.
|
|
|
Convert a linked list to an array.
|
1.4.1