|
|
| QCache (const QCache< type > &c) |
| |
|
| QCache (int maxCost=100, int size=17, bool caseSensitive=TRUE) |
| |
|
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 char *k, const type *d, int c=1, int p=0) |
| |
|
bool | remove (const char *k) |
| |
|
type * | take (const char *k) |
| |
|
type * | find (const char *k, bool ref=TRUE) const |
| |
|
type * | operator[] (const char *k) const |
| |
|
void | statistics () const |
| |
|
int | hits () const |
| |
|
int | misses () const |
| |
| bool | autoDelete () const |
| |
| void | setAutoDelete (bool enable) |
| |
|
|
typedef void * | Item |
| |
| enum | KeyType { StringKey,
AsciiKey,
IntKey,
PtrKey
} |
| |
|
| QGCache (int maxCost, uint size, KeyType kt, bool caseSensitive, bool copyKeys) |
| |
|
| QGCache (const QGCache &) |
| |
|
QGCache & | operator= (const QGCache &) |
| |
| uint | count () const |
| |
|
uint | size () const |
| |
|
int | maxCost () const |
| |
|
int | totalCost () const |
| |
|
void | setMaxCost (int maxCost) |
| |
| void | clear () |
| |
|
bool | insert_string (const QString &key, QCollection::Item, int cost, int priority) |
| |
|
bool | insert_other (const char *key, QCollection::Item, int cost, int priority) |
| |
|
bool | remove_string (const QString &key) |
| |
|
bool | remove_other (const char *key) |
| |
|
QCollection::Item | take_string (const QString &key) |
| |
|
QCollection::Item | take_other (const char *key) |
| |
|
QCollection::Item | find_string (const QString &key, bool ref=TRUE) const |
| |
|
QCollection::Item | find_other (const char *key, bool ref=TRUE) const |
| |
|
void | statistics () const |
| |
|
int | hits () const |
| |
|
int | misses () const |
| |
| | QCollection () |
| |
| | QCollection (const QCollection &) |
| |
| virtual | ~QCollection () |
| |
| virtual Item | newItem (Item) |
| |
|
bool | del_item |
| |
§ clear()
template<class type>
| void QCache< type >::clear |
( |
| ) |
|
|
inlinevirtual |
Removes all objects from the collection. The objects will be deleted if auto-delete has been enabled.
- See also
- setAutoDelete()
Implements QCollection.
§ count()
template<class type>
| uint QCache< type >::count |
( |
| ) |
const |
|
inlinevirtual |
Returns the number of objects in the collection.
Implements QCollection.
The documentation for this class was generated from the following file: