QPixmapCache::Key Class
class QPixmapCache::KeyDie Klasse „ QPixmapCache::Key “ kann für den effizienten Zugriff auf die „ QPixmapCache “ verwendet werden. Mehr...
Öffentliche Funktionen
Verwandte Nicht-Mitglieder
(since 6.6) size_t | qHash(const QPixmapCache::Key &key, size_t seed = 0) |
Ausführliche Beschreibung
Verwenden Sie ` QPixmapCache::insert()``, um eine vom Pixmap-Cache generierte Instanz von `Key` zu erhalten. Sie können den Schlüssel in Ihren eigenen Objekten speichern, um eine sehr effiziente Eins-zu-Eins-Zuordnung von Objekten zu Pixmaps zu erzielen.
Dokumentation der Mitgliedsfunktionen
Key::Key()
Erstellt ein leeres Key-Objekt.
[noexcept] Key::~Key()
Vernichtet den Schlüssel.
[noexcept] bool Key::isValid() const
Gibt ` true ` zurück, wenn mit diesem Schlüssel eine zwischengespeicherte Pixmap verknüpft ist. Andernfalls – wenn die Pixmap geleert wurde – ist der Schlüssel nicht mehr gültig.
[noexcept] void Key::swap(QPixmapCache::Key &other)
Tauscht diesen Schlüssel mit „ other “ aus. Dieser Vorgang ist sehr schnell und schlägt niemals fehl.
Verwandte Nicht-Mitglieder
[noexcept, since 6.6] size_t qHash(const QPixmapCache::Key &key, size_t seed = 0)
Gibt den Hash-Wert für „ key “ zurück, wobei „ seed “ als Startwert für die Berechnung verwendet wird.
Diese Funktion wurde in Qt 6.6 eingeführt.
© 2026 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.