contains

contains#

stdgpu: stdgpu::unordered_map::contains
stdgpu Latest
Efficient STL-like Data Structures on the GPU

◆ contains() [1/2]

template<typename Key , typename T , typename Hash = hash<Key>, typename KeyEqual = equal_to<Key>, typename Allocator = safe_device_allocator<pair<const Key, T>>>
STDGPU_DEVICE_ONLY bool stdgpu::unordered_map< Key, T, Hash, KeyEqual, Allocator >::contains ( const key_type key) const

Determines if the given key is stored in the container.

Parameters
[in]keyThe key
Returns
True if the requested key was found, false otherwise