QStack< T > Class Template Reference

Collaboration diagram for QStack< T >:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 QStack (const unsigned int ssize)
 QStack (const QStack< T > &s1)
 ~QStack ()
unsigned int entries () const
bool isEmpty () const
bool isNotEmpty () const
bool isFull () const
bool isNotFull () const
void lock ()
void unlock ()
bool push (T item)
pop ()
void clear ()

Private Member Functions

QStack< T > & operator= (QStack< T > &)

Private Attributes

T * stack
const unsigned int SIZE
unsigned int sp
int semaphore

Detailed Description

template<class T>
class QStack< T >

Quick Stack
      Use push() to add items and pop() to remove items.  Use the constructor's
      ssize parameter to set the size of the stack.


Constructor & Destructor Documentation

template<class T>
QStack< T >::QStack ( const unsigned int  ssize  )  [inline]

template<class T>
QStack< T >::QStack ( const QStack< T > &  s1  )  [inline]

template<class T>
QStack< T >::~QStack (  )  [inline]


Member Function Documentation

template<class T>
unsigned int QStack< T >::entries (  )  const [inline]

template<class T>
bool QStack< T >::isEmpty (  )  const [inline]

template<class T>
bool QStack< T >::isNotEmpty (  )  const [inline]

template<class T>
bool QStack< T >::isFull (  )  const [inline]

template<class T>
bool QStack< T >::isNotFull (  )  const [inline]

template<class T>
void QStack< T >::lock (  )  [inline]

template<class T>
void QStack< T >::unlock (  )  [inline]

template<class T>
bool QStack< T >::push ( item  )  [inline]

template<class T>
T QStack< T >::pop (  )  [inline]

template<class T>
void QStack< T >::clear (  )  [inline]

template<class T>
QStack<T>& QStack< T >::operator= ( QStack< T > &   )  [inline, private]


Member Data Documentation

template<class T>
T* QStack< T >::stack [private]

The Stack.

template<class T>
const unsigned int QStack< T >::SIZE [private]

Max size of the stack.

template<class T>
unsigned int QStack< T >::sp [private]

Stack pointer.

template<class T>
int QStack< T >::semaphore [private]

ref(), unref() semaphore


Generated on Tue Dec 19 16:25:43 2006 for Eaagles by  doxygen 1.5.0