List_t< T > Class Template Reference

Template list class, implemented as a circular array of pointers to T.

#include <UTLists.h>

Inheritance diagram for List_t< T >:
Array_t< T * > OwnedList_t< T >

List of all members.

Public Member Functions

 List_t ()
 List_t (T **stack_buffer, int stack_buffer_num_items_allcoated)
T * RemoveItem (T *item)
int IndexOfItem (T *item)
T & operator[] (int index) const
void operator-= (T *item)

Detailed Description

template<class T>
class List_t< T >

Definition at line 142 of file UTLists.h.


Constructor & Destructor Documentation

template<class T >
List_t< T >::List_t (  )  [inline]

Constructor for an empty list.

Definition at line 1557 of file UTLists.h.

template<class T>
List_t< T >::List_t ( T **  stack_buffer,
int  stack_buffer_num_items_allcoated 
) [inline]

Constructor for a list which initially uses a stack-allocated buffer of the specified size. If the required size grows beyond that size, the buffer will be reallocated from the heap.

Definition at line 1563 of file UTLists.h.


Member Function Documentation

template<class T>
T * List_t< T >::RemoveItem ( T *  item  )  [inline]

Removes and returns the item at the specified position in the list.

Definition at line 1570 of file UTLists.h.

template<class T>
int List_t< T >::IndexOfItem ( T *  item  )  [inline]

Returns the index of the specified item, or -1 if it is not found in the list.

Definition at line 1587 of file UTLists.h.

template<class T >
T & List_t< T >::operator[] ( int  index  )  const [inline]

Returns the item at the specified position in the list by reference, where the head is index 0.

Reimplemented from Array_t< T * >.

Definition at line 1598 of file UTLists.h.

template<class T>
void List_t< T >::operator-= ( T *  item  )  [inline]

Searches for and removes the specified item from the list.

Definition at line 1606 of file UTLists.h.


The documentation for this class was generated from the following file:

Generated on Tue Dec 14 22:35:07 2010 for UT library by  doxygen 1.6.1