- FreeMode
- FreeMode
- Total
- IsSorted
- SortMode
- CreateElement
- Add
- Insert
- DetachCurrent
- DeleteCurrent
- Delete
- Clear
- IndexOf
- GetNodeAtIndex
- GetFirstNode
- GetPrevNode
- GetCurrentNode
- GetNextNode
- GetLastNode
- Sort
- MoveToIndex
- Exchange
- CompareList
- Search
- Save
- Load
- Type
Add
Adds an element to the end of the list.
int Add(
|
Parameters
element
[in] Value of the element to add to the list.
Return Value
Index of the added element - success, -1 - error.
Note
The element is not added to the list, if an invalid pointer (for example, NULL) is passed as a parameter.
Example:
//--- example for CList::Add(Cobject*)
|