Erase all elements in ms that satisfy predicate.
Declared in <bslstl_multiset.h>
template<
class KEY,
class COMPARATOR,
class ALLOCATOR,
class PREDICATE>
bsl::multiset<KEY, COMPARATOR, ALLOCATOR>::size_type
erase_if(
multiset<KEY, COMPARATOR, ALLOCATOR>& ms,
PREDICATE predicate);
Erase all the elements in the specified multiset ms that satisfy the specified predicate predicate. Return the number of elements erased.
number of elements erased
| Name | Description |
|---|---|
| ms | multiset from which to erase elements |
| predicate | unary predicate selecting elements to erase |