Diligent Engine
 
Loading...
Searching...
No Matches
Diligent::WeakValueHashMap< KeyType, ValueType, Hasher, Keyeq >::ValueHandle Class Reference

ValueHandle is a handle to a value in the WeakValueHashMap. More...

#include <WeakValueHashMap.hpp>

Detailed Description

template<typename KeyType, typename ValueType, typename Hasher = std::hash<KeyType>, typename Keyeq = std::equal_to<KeyType>>
class Diligent::WeakValueHashMap< KeyType, ValueType, Hasher, Keyeq >::ValueHandle

ValueHandle is a handle to a value in the WeakValueHashMap.

It holds a strong pointer to the value (and keeps the map implementation alive while the handle exists). The map entry is removed by the value's custom deleter when the last strong reference to the value is destroyed.