count overloads
Declared in <bslstl_map.h>
Return the number of value_type objects within this map whose keys are equivalent to the specified key. Note that since a map maintains unique keys, the returned value will be either 0 or 1.
size_type
count(key_type const& key) const;
» more...
Return the number of value_type objects within this map whose keys are equivalent to the specified key. Note that although a map maintains unique keys, the returned value can be other than 0 or 1, because a transparent comparator may have been supplied that provides a different (but compatible) partitioning of keys for LOOKUP_KEY as the comparisons used to order the keys in the map.
template<class LOOKUP_KEY>
size_type
count(LOOKUP_KEY const& key) const
requires BloombergLP::bslmf::IsTransparentPredicate<COMPARATOR,
LOOKUP_KEY>::value;
» more...