KMIME Library
#include <kautodeletehash.h>
Inherits QHash< Key, T * >.
Public Member Functions | |
KAutoDeleteHash () | |
KAutoDeleteHash (const QHash< Key, T * > &other) | |
~KAutoDeleteHash () | |
Detailed Description
template<class Key, class T>
class KMime::KAutoDeleteHash< Key, T >
The KAutoDeleteHash class is a convenience QHash subclass that provides automatic deletion of the values in the destructor.
Apart from this KAutoDeleteHash behaves exactly like QHash<Key, T *>.
Since the automatic deletion is restricted to the destruction of the hash you have take care of the deletion of values you remove or replace yourself. To replace a value in the hash by another value use
and to remove a value from the hash use
Definition at line 49 of file kautodeletehash.h.
Constructor & Destructor Documentation
|
inline |
Constructs an empty hash.
Definition at line 55 of file kautodeletehash.h.
|
inline |
Constructs a copy of other
(which can be a QHash or a KAutoDeleteHash).
Definition at line 59 of file kautodeletehash.h.
|
inline |
Destroys the hash and deletes all values.
References to the values in the hash and all iterators of this hash become invalid.
Definition at line 65 of file kautodeletehash.h.
The documentation for this class was generated from the following file:
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 23:00:11 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.