The TryEmplaceResult class is used to represent the result of a tryEmplace () operation. 更多...
This struct was introduced in Qt 6.9.
| bool | inserted |
| QHash<Key, T>::iterator | iterator |
The
TryEmplaceResult
class is used in
QHash
to represent the result of a
tryEmplace
() operation. It holds an
iterator
to the newly created item, or to the pre-existing item that prevented the insertion, and a boolean,
inserted
, denoting whether the insertion took place.
另请参阅 QHash and QHash::tryEmplace ().
This value is
false
if there was already an entry with the same key.
Holds the iterator to the newly inserted element, or the element that prevented the insertion.