Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

QCache< type > Class Template Reference

#include </home/clem/local/src/opie/qmake/include/qcache.h>

Inheritance diagram for QCache< type >:

Inheritance graph
[legend]
Collaboration diagram for QCache< type >:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 QCache (const QCache< type > &c)
 QCache (int maxCost=100, int size=17, bool caseSensitive=TRUE)
 ~QCache ()
QCache< type > & operator= (const QCache< type > &c)
int maxCost () const
int totalCost () const
void setMaxCost (int m)
uint count () const
uint size () const
bool isEmpty () const
void clear ()
bool insert (const QString &k, const type *d, int c=1, int p=0)
bool remove (const QString &k)
typetake (const QString &k)
typefind (const QString &k, bool ref=TRUE) const
typeoperator[] (const QString &k) const
void statistics () const
template<>
void deleteItem (QPtrCollection::Item)

Private Member Functions

void deleteItem (Item d)

template<class type>
class QCache< type >


Constructor & Destructor Documentation

template<class type>
QCache< type >::QCache const QCache< type > &  c  )  [inline]
 

Definition at line 54 of file qcache.h.

template<class type>
QCache< type >::QCache int  maxCost = 100,
int  size = 17,
bool  caseSensitive = TRUE
[inline]
 

Definition at line 55 of file qcache.h.

template<class type>
QCache< type >::~QCache  )  [inline]
 

Definition at line 57 of file qcache.h.


Member Function Documentation

template<class type>
void QCache< type >::clear  )  [inline, virtual]
 

Clears the cache.

Reimplemented from QGCache.

Definition at line 66 of file qcache.h.

Referenced by QCache< QFontStruct >::~QCache().

template<class type>
uint QCache< type >::count  )  const [inline, virtual]
 

Returns the number of items in the cache.

Reimplemented from QGCache.

Definition at line 63 of file qcache.h.

template<>
void QCache< void >::deleteItem QPtrCollection::Item   )  [inline]
 

Definition at line 83 of file qcache.h.

template<class type>
void QCache< type >::deleteItem Item  d  )  [inline, private]
 

Reimplemented in QFontCache.

Definition at line 88 of file qcache.h.

References QPtrCollection::del_item, and type.

template<class type>
type* QCache< type >::find const QString k,
bool  ref = TRUE
const [inline]
 

Definition at line 73 of file qcache.h.

Referenced by FlatDecoration::drawButton(), SkinCache::lookupAndTake(), and SkinCache::store().

template<class type>
bool QCache< type >::insert const QString k,
const type d,
int  c = 1,
int  p = 0
[inline]
 

Definition at line 67 of file qcache.h.

Referenced by derefEngine(), FlatDecoration::drawButton(), and SkinCache::store().

template<class type>
bool QCache< type >::isEmpty  )  const [inline]
 

Definition at line 65 of file qcache.h.

template<class type>
int QCache< type >::maxCost  )  const [inline]
 

Returns the maximum cache cost.

Reimplemented from QGCache.

Definition at line 60 of file qcache.h.

template<class type>
QCache<type>& QCache< type >::operator= const QCache< type > &  c  )  [inline]
 

Definition at line 58 of file qcache.h.

template<class type>
type* QCache< type >::operator[] const QString k  )  const [inline]
 

Definition at line 75 of file qcache.h.

template<class type>
bool QCache< type >::remove const QString k  )  [inline]
 

Definition at line 69 of file qcache.h.

template<class type>
void QCache< type >::setMaxCost int  m  )  [inline]
 

Sets the maximum cache cost to maxCost.

Reimplemented from QGCache.

Definition at line 62 of file qcache.h.

Referenced by SkinCache::SkinCache().

template<class type>
uint QCache< type >::size  )  const [inline]
 

Returns the size of the hash array.

Reimplemented from QGCache.

Definition at line 64 of file qcache.h.

template<class type>
void QCache< type >::statistics  )  const [inline]
 

Outputs debug statistics.

Reimplemented from QGCache.

Definition at line 77 of file qcache.h.

template<class type>
type* QCache< type >::take const QString k  )  [inline]
 

Definition at line 71 of file qcache.h.

Referenced by SkinCache::lookupAndTake(), and newEngine().

template<class type>
int QCache< type >::totalCost  )  const [inline]
 

Returns the total cache cost.

Reimplemented from QGCache.

Definition at line 61 of file qcache.h.


The documentation for this class was generated from the following file:
Generated on Sat Nov 5 17:46:06 2005 for OPIE by  doxygen 1.4.2