zmm::ObjectQueue< T > Class Template Reference

a simple stack for a base type. NOT thread safe! More...

#include <object_queue.h>

Inheritance diagram for zmm::ObjectQueue< T >:
zmm::BaseQueue< Object * > zmm::Object

Public Member Functions

 ObjectQueue (int initialCapacity)
 ~ObjectQueue ()
void enqueue (Ref< T > element)
Ref< T > dequeue ()
Ref< T > get (int index)
int getCapacity ()
int size ()
bool isEmpty ()
void resize (int requiredSize)
void enqueue (Object *element)
void retain ()
void release ()
int getRefCount ()

Static Public Member Functions

static void * operator new (size_t size)
static void operator delete (void *ptr)

Protected Attributes

Object ** data
ObjectemptyType
int capacity
int queueBegin
int queueEnd
bool overlap
mt_atomic_t _ref_count
pthread_mutex_t mutex

Detailed Description

template<class T>
class zmm::ObjectQueue< T >

a simple stack for a base type. NOT thread safe!

Definition at line 42 of file object_queue.h.


Constructor & Destructor Documentation

template<class T>
zmm::ObjectQueue< T >::ObjectQueue ( int  initialCapacity  )  [inline]

Definition at line 45 of file object_queue.h.

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

Definition at line 49 of file object_queue.h.


Member Function Documentation

template<class T>
Ref<T> zmm::ObjectQueue< T >::dequeue (  )  [inline]

Reimplemented from zmm::BaseQueue< Object * >.

Definition at line 65 of file object_queue.h.

Referenced by zmm::ObjectQueue< AutoscanDirectory >::dequeue().

void zmm::BaseQueue< Object * >::enqueue ( Object element  )  [inline, inherited]
template<class T>
void zmm::ObjectQueue< T >::enqueue ( Ref< T >  element  )  [inline]

Definition at line 58 of file object_queue.h.

Referenced by zmm::ObjectQueue< AutoscanDirectory >::enqueue().

template<class T>
Ref<T> zmm::ObjectQueue< T >::get ( int  index  )  [inline]

Reimplemented from zmm::BaseQueue< Object * >.

Definition at line 75 of file object_queue.h.

Referenced by zmm::ObjectQueue< AutoscanDirectory >::get().

int zmm::BaseQueue< Object * >::getCapacity (  )  [inline, inherited]

Definition at line 59 of file base_queue.h.

References zmm::BaseQueue< T >::capacity.

int Object::getRefCount (  )  [inherited]

Definition at line 78 of file object.cc.

References zmm::Object::_ref_count, and atomic_get().

bool zmm::BaseQueue< Object * >::isEmpty (  )  [inline, inherited]
void Object::operator delete ( void *  ptr  )  [static, inherited]

Definition at line 87 of file object.cc.

References FREE.

void * Object::operator new ( size_t  size  )  [static, inherited]

Definition at line 83 of file object.cc.

References MALLOC.

void Object::release (  )  [inherited]
void zmm::BaseQueue< Object * >::resize ( int  requiredSize  )  [inline, inherited]
void Object::retain (  )  [inherited]
int zmm::BaseQueue< Object * >::size (  )  [inline, inherited]

Field Documentation

mt_atomic_t zmm::Object::_ref_count [protected, inherited]
int zmm::BaseQueue< Object * >::capacity [protected, inherited]

Definition at line 131 of file base_queue.h.

Object * * zmm::BaseQueue< Object * >::data [protected, inherited]

Definition at line 129 of file base_queue.h.

Object * zmm::BaseQueue< Object * >::emptyType [protected, inherited]

Definition at line 130 of file base_queue.h.

pthread_mutex_t zmm::Object::mutex [protected, inherited]
bool zmm::BaseQueue< Object * >::overlap [protected, inherited]

Definition at line 134 of file base_queue.h.

int zmm::BaseQueue< Object * >::queueBegin [protected, inherited]

Definition at line 132 of file base_queue.h.

int zmm::BaseQueue< Object * >::queueEnd [protected, inherited]

Definition at line 133 of file base_queue.h.


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

Generated on Fri Mar 26 20:16:59 2010 for MediaTomb by  doxygen 1.6.1