| |
Main Page Namespace List Class Hierarchy Alphabetical List Compound List Namespace Members Compound Members
PLMUList< T > Class Template ReferenceUnordered list (template container).
More...
#include <PLMUList.hpp>
List of all members.
Detailed Description
template<class T>
class PLMUList< T >
Unordered list (template container).
Notes:
- Elements can be any object (only pointers are stored),
- Implemented like a vector (fast access),
- Remove = replace element by last element in the list,
- The list can never have "holes" and order is modified by remove calls,
- New elements are added at the end,
- Defaults : size = increment = 5, elements are not deleted on destruction.
Constructor & Destructor Documentation
|
template<class T> |
| PLMUList< T >::PLMUList |
( |
u32 |
startsize = 5 |
) |
|
|
|
template<class T> |
| PLMUList< T >::~PLMUList |
( |
|
) |
|
|
|
|
Delete elements according to destruction policy (see SetDOD).
|
Member Function Documentation
|
template<class T> |
| u32 PLMUList< T >::Size |
( |
|
) |
[inline] |
|
|
|
Get the number of cells currently allocated (free + used). - See also:
-
Length().
|
|
template<class T> |
| u32 PLMUList< T >::Length |
( |
|
) |
[inline] |
|
|
|
Get the number of elements currently in the list (used cells). - See also:
-
Size().
|
|
template<class T> |
| u32 PLMUList< T >::Add |
( |
T * |
t |
) |
|
|
|
|
Adds an element to the ulist and returns its index (it may change later !).
|
|
template<class T> |
| void PLMUList< T >::Remove |
( |
T * |
t, |
|
|
PLM::Deletion |
del = PLM::DEL_NONE |
|
) |
|
|
|
|
Remove the first element that equals t and delete it according to del.
The last element of the list is moved to fill this empty place. |
|
template<class T> |
| void PLMUList< T >::Remove |
( |
u32 |
t, |
|
|
PLM::Deletion |
del = PLM::DEL_NONE |
|
) |
|
|
|
|
Remove the element at index t and delete it according to del.
The last element of the list is moved to fill this empty place. |
|
template<class T> |
| T * PLMUList< T >::Get |
( |
u32 |
i |
) |
const [inline] |
|
|
|
Get element at index i. Return NULL if i is out of range.
|
|
template<class T> |
| void PLMUList< T >::SetDOD |
( |
PLM::Deletion |
del |
) |
[inline] |
|
|
|
Define the behaviour on destruction.
Tell wether or not elements should be deleted on destruction and how :
|
|
template<class T> |
| int PLMUList< T >::GetDOD |
( |
|
) |
[inline] |
|
|
|
Get current destruction behaviour. - See also:
-
SetDOD().
|
The documentation for this class was generated from the following file:
Generated by
Doxygen 1.2.18 on Tue Oct 26 12:07:45 2004.
|