This class template implements a value‐semantic container type holding an unordered set of unique values (of template parameter type KEY).
Synopsis
Declared in <bslstl_unorderedset.h>
template<
class KEY,
class HASH = bsl::hash<KEY>,
class EQUAL = bsl::equal_to<KEY>,
class ALLOCATOR = bsl::allocator<KEY>>
class unordered_set;
Description
This class: * supports a complete set of value‐semantic operations
-
except for BDEX serialization * is exception‐neutral (agnostic except for the
atmethod) * is alias‐safe * isconstthread‐safe For terminology see {`bsldoc_glossary`}.
Type Aliases
Name |
Description |
This |
|
This |
|
This |
|
This |
|
This |
|
This |
|
This |
|
This |
|
This |
|
This |
|
This |
|
This |
|
This |
|
This |
|
This |
Member Functions
Name |
Description |
|
Constructors |
|
Destroy this object. |
Assignment operators |
|
|
|
Return the bucket index for the specified |
|
Return the number of buckets in the array of buckets maintained by this set. |
|
Return the number of elements in the bucket at |
|
|
|
|
|
Remove all entries from this unordered set. Note that the set is empty after this call, but allocated memory may be retained for future use. |
|
|
|
Return the number of elements equivalent to |
|
Emplace a newly constructed element if the key is missing. |
|
Emplace a newly constructed element using |
|
Return |
|
|
|
Return the range of elements equivalent to |
|
|
|
Return an iterator to the element equivalent to |
|
Return (a copy of) the allocator used for memory allocation by this unordered set. |
|
Return (a copy of) the hash unary functor used by this set to generate a hash value (of type |
|
|
|
Insert values from |
|
Return (a copy of) the key‐equality binary functor that returns |
|
Return the current load factor of this container. |
|
Return a theoretical upper bound on the number of buckets. |
|
|
|
Return a theoretical upper bound on this set's size. |
|
Rehash this set to have at least |
|
Reserve capacity for at least |
|
Return the number of elements in this set. |
|
Exchange the contents of this set with |
|
Return the nested trait declaration for |
Deduction Guides
Name |
Description |
CTAD guide: deduce |
|
CTAD guide: deduce |
|
CTAD guide: deduce |
|
CTAD guide: deduce |
|
CTAD guide: deduce |
|
CTAD guide: deduce |
|
CTAD guide: deduce |
|
CTAD guide: deduce |
|
CTAD guide: deduce |
|
CTAD guide: deduce |
|
|
CTAD guide: deduce |
|
CTAD guide: deduce |
|
CTAD guide: deduce |
|
CTAD guide: deduce |
|
CTAD guide: deduce |
|
CTAD guide: deduce |
Friends
Name |
Description |
Return |
Non-Member Functions
Name |
Description |
Erase elements from |
|
Return |
|
Exchange the contents of |
Created with MrDocs