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 | |
| bool | psMemCheckList (psPtr ptr) |
| Checks the type of a particular pointer. | |
| psList * | psListAlloc (psPtr data) |
| Creates a psList linked list object. | |
| psListIterator * | psListIteratorAlloc (psList *list, long location, bool mutable) |
| Creates a psListIterator object and associates it with a psList. | |
| bool | psListIteratorSet (psListIterator *iterator, long location) |
| Set the iterator of the list to a given position. | |
| bool | psListAdd (psList *list, long location, psPtr data) |
| Adds an element to a psList at position given. | |
| bool | psListAddAfter (psListIterator *iterator, psPtr data) |
| Adds an data item to a psList at position just after the list position given. | |
| bool | psListAddBefore (psListIterator *iterator, psPtr data) |
| Adds an data item to a psList at position just before the list position given. | |
| bool | psListRemove (psList *list, long location) |
| Remove an item at the specified location from a list. | |
| bool | psListRemoveData (psList *list, psPtr data) |
| Remove an item from a list. | |
| psPtr | psListGet (psList *list, long 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 (const psList *list) |
| Convert a linked list to an array. | |
| psList * | psArrayToList (const psArray *array) |
| Convert array to a doubly-linked list. | |
| psList * | psListSort (psList *list, psComparePtrFunc func) |
| 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.
|
|
|
Checks the type of a particular pointer. Uses the appropriate deallocation function in psMemBlock to check the ptr datatype.
|
1.4.2