Main Page | Modules | Namespace List | Class Hierarchy | Class List | File List | Namespace Members | Class Members | File Members

ustl::list< T > Class Template Reference
[Sequence Containers]

Linked list emulator. More...

#include <ustl.h>

Inheritance diagram for ustl::list< T >:

ustl::vector< T > ustl::memblock ustl::memlink ustl::cmemlink List of all members.

Public Types

typedef vector< T >::size_type size_type
typedef vector< T >::iterator iterator
typedef vector< T >::const_iterator const_iterator
typedef vector< T >::reference reference
typedef vector< T >::const_reference const_reference

Public Member Functions

 list (size_type n)
 list (size_type n, const T &v)
 list (const list< T > &v)
 list (const_iterator i1, const_iterator i2)
size_type size (void) const
 Returns the size of the block.
iterator begin (void)
 Returns a modifiable pointer to the block.
const_iterator begin (void) const
 Returns a const pointer to the block.
iterator end (void)
 Returns a modifiable pointer to the end of the block.
const_iterator end (void) const
 Returns a const pointer to the end of the block.
void push_front (const T &v)
void pop_front (void)
const_reference front (void) const
 Returns the const reference to the first element.
reference front (void)
 Returns the reference to the first element.
void remove (const T &v)
void unique (void)
void sort (void)
void merge (list< T > &l)
 Merges the contents with l. Assumes both lists are sorted.
void splice (iterator ip, list< T > &l, iterator first=NULL, iterator last=NULL)
 Moves the range [first, last) from l to this list at ip.

Detailed Description

template<typename T>
class ustl::list< T >

Linked list emulator.

The list template is aliased to vector for philosophical reasons. I believe the use of linked lists of any kind to be an indicator of bad design. It is simply the wrong way of thinking about storage. The alias is provided for compatibility with the C++ standard and is mostly inline.


The documentation for this class was generated from the following file:
Generated on Mon Jan 17 14:35:03 2005 for uSTL by 1.3.9 Doxygen Hosted on SourceForge.net