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 index of the bucket, in the array of buckets of this container, where a value equivalent to the specified |
|
Return the number of buckets in the array of buckets maintained by this set. |
|
Return the number of elements contained in the bucket at the specified |
|
|
|
|
|
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 |
|
|
|
Insert into this unordered set a newly created |
|
Insert into this unordered set a newly created |
|
Return |
|
|
|
|
|
|
|
|
|
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 into this set the value of each |
|
Return (a copy of) the key‐equality binary functor that returns |
|
Return the current ratio between the |
|
Return a theoretical upper bound on the largest number of buckets that this container could possibly manage. Note that there is no guarantee that the set can successfully grow to the returned size, or even close to that size without running out of resources. |
|
|
|
Return a theoretical upper bound on the largest number of elements that this set could possibly hold. Note that there is no guarantee that the set can successfully grow to the returned size, or even close to that size without running out of resources. |
|
Change the size of the array of buckets maintained by this container to the specified |
|
Increase the number of buckets of this set to a quantity such that the ratio between the specified |
|
Return the number of elements in this set. |
|
Exchange the value, hasher, key‐equality functor, and |
|
Declare nested type traits for this type. |
Specializations
Name |
Description |
This class template implements a value‐semantic container type holding an unordered set of unique values (of template parameter type |
|
This class template implements a value‐semantic container type holding an unordered set of unique values (of template parameter type |
Deduction Guides
Name |
Description |
Deduce the template parameter |
|
Deduce the template parameter |
|
Deduce the template parameter |
|
Deduce the template parameter |
|
Deduce the template parameter |
|
Deduce the template parameter |
|
Deduce the template parameter |
|
Deduce the template parameter |
|
Deduce the template parameter |
|
Deduce the template parameter |
|
|
Deduce the template parameter |
|
Deduce the template parameter |
|
Deduce the template parameter |
|
Deduce the template parameter |
|
Deduce the template parameter |
|
Deduce the template parameter |
Friends
Name |
Description |
Return |
Non-Member Functions
Name |
Description |
Erase all the elements in the specified unordered_set |
|
Return |
|
Exchange the value, hasher, key‐equality functor, and |
Created with MrDocs