#include <TValListT.hh>
Public Methods | |
| TValListT () | |
| Constructs an empty list. | |
| TValListT (TValListT< T > &list) | |
| Copy constructor. | |
| ~TValListT () | |
| Destructor. | |
| void | Append (T a) |
| Add an element to the end of the list. | |
| void | Apply (void(*fn)(T *, void *), void *d) |
| Applies the user defined function to every element in the list. | |
| void | Clear () |
| Remove all elements from the list. | |
| int | Entries () const |
| Return the number of entries in the list. | |
| T | First () |
| Return the first element of the list. | |
| void | Insert (T a, int i=0) |
| Add an element before the specified entry. | |
| T | Last () |
| Return the last element of the list. | |
| T | Remove (int i=0) |
| Remove element at the specified position. | |
| T | RemoveLast () |
| Remove the last element of the list. | |
| void | Sort (bool reverse=false) |
| Sort all entries in self with the less than operator (<). | |
| T & | operator[] (int i) |
| Index operator. | |
| TValListT< T > & | operator= (const TValListT< T > &list) |
| Assignment operator. | |
|
||||||||||||||||
|
Applies the user defined function to every element in the list.
|
|
|||||||||
|
Return the first element of the list. Null is returned if the list is empty. |
|
|||||||||
|
Return the last element of the list. Null is returned if the list is empty. |
|
||||||||||
|
Index operator. Returns a reference to the object so that it may be modified. |
|
||||||||||
|
Sort all entries in self with the less than operator (<).
|
1.3-rc2