erase overloads
Declared in <bdlc_flathashmap.h>
Remove from this map the element at the specified position, and return an iterator referring to the modifiable element immediately following the removed element, or to the past-the-end position if the removed element was the last element in the sequence of elements maintained by this map. This method invalidates all iterators and references to the removed element. The behavior is undefined unless position refers to an element in this map.
FlatHashMap<KEY, VALUE, HASH, EQUAL>::iterator
erase(const_iterator position);
» more...
Same as the preceding overload for a non-const iterator.
FlatHashMap<KEY, VALUE, HASH, EQUAL>::iterator
erase(iterator position);
» more...
Remove from this map the element whose key is equal to the specified key, if it exists, and return 1; otherwise (there is no element having key in this map), return 0 with no other effect. This method invalidates all iterators and references to the removed element.
std::size_t
erase(KEY const& key);
» more...
Remove from this map the element whose key is equivalent to the specified key, if it exists, and return 1; otherwise (there is no element equivalent to key in this map), return 0 with no other effect. This method invalidates all iterators and references to the removed element.
template<class LOOKUP_KEY>
std::size_t
erase(LOOKUP_KEY&& key)
requires BloombergLP::bslmf::IsTransparentPredicate<HASH, LOOKUP_KEY>::value
&& BloombergLP::bslmf::IsTransparentPredicate<EQUAL,LOOKUP_KEY>::value;
» more...
Remove from this map the elements starting at the specified first position up to, but not including, the specified last position, and return an iterator referencing the same element as last. This method invalidates all iterators and references to the removed elements. The behavior is undefined unless first and last are valid iterators on this map, and the first position is at or before the last position in the iteration sequence provided by this container.
FlatHashMap<KEY, VALUE, HASH, EQUAL>::iterator
erase(
const_iterator first,
const_iterator last);
» more...