bsl::unordered_multiset::count

Return the number of elements equivalent to key.

Synopsis

Declared in <bslstl_unorderedmultiset.h>

template<class LOOKUP_KEY>
size_type
count(LOOKUP_KEY const& key) const
requires BloombergLP::bslmf::IsTransparentPredicate<HASH, LOOKUP_KEY>::value
        && BloombergLP::bslmf::IsTransparentPredicate<EQUAL,LOOKUP_KEY>::value;

Description

Return the number of value_type objects within this unordered multiset that are equivalent to the specified key. The behavior is undefined unless key is equivalent to the elements of at most one equivalent-key group in this unordered multiset.

Return Value

number of elements equivalent to key

Parameters

NameDescription
keykey value to count