Try to emplace an element with transparent key near hint.
Synopsis
Declared in <bslstl_map.h>
template<
class LOOKUP_KEY,
class... Args>
iterator
try_emplace(
const_iterator hint,
LOOKUP_KEY&& key,
Args&&... args)
requires BloombergLP::bslmf::IsTransparentPredicate<COMPARATOR,
LOOKUP_KEY>::value;
Description
Insert at the specified hint using the transparent LOOKUP_KEY and the specified constructor args, or return an iterator to an existing entry.
Return Value
iterator to the existing or newly inserted element
Parameters
Name |
Description |
hint |
iterator hint for the insertion position |
key |
transparent key for the element to emplace |
args |
constructor arguments for the mapped value |
Created with MrDocs