MDeque< T > Class Template Reference

#include <MercuryVector.h>

Inheritance diagram for MDeque< T >:

Inheritance graph
[legend]
List of all members.

Public Member Functions

 MDeque ()
 ~MDeque ()
 MDeque (const MDeque &rhs)
MDequeoperator= (const MDeque &rhs)
void swap (MDequeIterator< T > &p1, MDequeIterator< T > &p2)
 Swap two iterator's pointers and connections.
void push_front (const T &pData)
 Push new element copy onto the front of the stack.
void push_back (const T &pData)
 Push new element copy onto the end of the stack.
void pop_front ()
 Remove the first element.
void pop_back ()
 Remove the last element.
T & front () const
 Return the object in the front of the deque.
T & back () const
 Return the object at the end of the deque.
unsigned int size () const
 Get the size of the deque.
bool empty () const
 See if the deque is empty.
MDequeIterator< T > begin ()
 Get iterator to beginning of the deque.
MDequeIterator< T > & end ()
 Get invalid iterator, all MDeques have the same end().
const MDequeIterator< T > begin () const
 Get const iterator to beginning of the deque.
const MDequeIterator< T > & end () const
 Get const invalid iterator, all MDeques have the same end().
MDequeIterator< T > find (const T &fCmp)
 Find a given element in the deque, then return an iterator to it.
void erase (MDequeIterator< T > &p)
 Erase a given iterator from the deque.

Private Attributes

unsigned int iSize
MDequeIterator< T > Nil
MDequeNode< T > * Temp
MDequeNode< T > * Head
MDequeNode< T > * Tail

Detailed Description

template<typename T>
class MDeque< T >

Definition at line 256 of file MercuryVector.h.


Constructor & Destructor Documentation

template<typename T>
MDeque< T >::MDeque (  )  [inline]

Definition at line 259 of file MercuryVector.h.

template<typename T>
MDeque< T >::~MDeque (  )  [inline]

Definition at line 260 of file MercuryVector.h.

template<typename T>
MDeque< T >::MDeque ( const MDeque< T > &  rhs  )  [inline]

Definition at line 262 of file MercuryVector.h.


Member Function Documentation

template<typename T>
MDeque& MDeque< T >::operator= ( const MDeque< T > &  rhs  )  [inline]

Definition at line 272 of file MercuryVector.h.

template<typename T>
void MDeque< T >::swap ( MDequeIterator< T > &  p1,
MDequeIterator< T > &  p2 
) [inline]

Swap two iterator's pointers and connections.

Definition at line 284 of file MercuryVector.h.

template<typename T>
void MDeque< T >::push_front ( const T &  pData  )  [inline]

Push new element copy onto the front of the stack.

Definition at line 350 of file MercuryVector.h.

template<typename T>
void MDeque< T >::push_back ( const T &  pData  )  [inline]

Push new element copy onto the end of the stack.

Definition at line 352 of file MercuryVector.h.

template<typename T>
void MDeque< T >::pop_front (  )  [inline]

Remove the first element.

Definition at line 354 of file MercuryVector.h.

template<typename T>
void MDeque< T >::pop_back (  )  [inline]

Remove the last element.

Definition at line 356 of file MercuryVector.h.

template<typename T>
T& MDeque< T >::front (  )  const [inline]

Return the object in the front of the deque.

Definition at line 358 of file MercuryVector.h.

template<typename T>
T& MDeque< T >::back (  )  const [inline]

Return the object at the end of the deque.

Definition at line 360 of file MercuryVector.h.

template<typename T>
unsigned int MDeque< T >::size (  )  const [inline]

Get the size of the deque.

Definition at line 362 of file MercuryVector.h.

template<typename T>
bool MDeque< T >::empty (  )  const [inline]

See if the deque is empty.

Definition at line 364 of file MercuryVector.h.

template<typename T>
MDequeIterator<T> MDeque< T >::begin (  )  [inline]

Get iterator to beginning of the deque.

Definition at line 367 of file MercuryVector.h.

template<typename T>
MDequeIterator<T>& MDeque< T >::end (  )  [inline]

Get invalid iterator, all MDeques have the same end().

Definition at line 369 of file MercuryVector.h.

template<typename T>
const MDequeIterator<T> MDeque< T >::begin (  )  const [inline]

Get const iterator to beginning of the deque.

Definition at line 372 of file MercuryVector.h.

template<typename T>
const MDequeIterator<T>& MDeque< T >::end (  )  const [inline]

Get const invalid iterator, all MDeques have the same end().

Definition at line 374 of file MercuryVector.h.

template<typename T>
MDequeIterator<T> MDeque< T >::find ( const T &  fCmp  )  [inline]

Find a given element in the deque, then return an iterator to it.

Definition at line 377 of file MercuryVector.h.

template<typename T>
void MDeque< T >::erase ( MDequeIterator< T > &  p  )  [inline]

Erase a given iterator from the deque.

Definition at line 389 of file MercuryVector.h.


Member Data Documentation

template<typename T>
unsigned int MDeque< T >::iSize [private]

Definition at line 424 of file MercuryVector.h.

template<typename T>
MDequeIterator<T> MDeque< T >::Nil [private]

Definition at line 425 of file MercuryVector.h.

template<typename T>
MDequeNode<T>* MDeque< T >::Temp [private]

Definition at line 426 of file MercuryVector.h.

template<typename T>
MDequeNode<T>* MDeque< T >::Head [private]

Definition at line 427 of file MercuryVector.h.

template<typename T>
MDequeNode<T>* MDeque< T >::Tail [private]

Definition at line 428 of file MercuryVector.h.


The documentation for this class was generated from the following file:
Hosted by SourceForge.net Logo