Member | Description |
---|---|
std::pair<iterator, bool> insert(const value_type& x) |
Constructs copy of x and attempts to insert it into the set. Destroys the copy if the attempt fails because there was already an item with the same key. Returns: std::pair(iterator,success). The value iterator points to an item in the set with a matching key. The value of success is true if the item was inserted; false otherwise. |
iterator insert(const_iterator hint, const value_type& x) |
Same as insert(x). NoteThe current implementation ignores the hint argument. Other implementations might not ignore it. It exists for similarity with the C++11 classes unordered_set and unordered_multiset. It hints to the implementation about where to start searching. Typically it should point to an item adjacent to where the item will be inserted. Returns: Iterator pointing to inserted item, or item already in the set with the same key. |
template<class InputIterator> void insert(InputIterator first, InputIterator last) |
Does insert(*i) where i is in the half-open interval [first,last). |
iterator unsafe_erase(const_iterator position) |
Removes the item pointed to by position from the set. Returns: Iterator pointing to item that was immediately after the erased item, or end() if erased item was the last item in the set. |
size_type unsafe_erase(const key_type& k) |
Removes item with key k if such an item exists. Returns: 1 if an item was removed; 0 otherwise. |
iterator unsafe_erase(const_iterator first, const_iterator last) |
Removes *i where i is in the half-open interval [first,last). Returns: last |
void clear() |
Removes all items from the set. |
Member | Description |
---|---|
void swap(concurrent_unordered_set& m) |
Swaps contents of *this and m. |
Member | Description |
---|---|
void swap(concurrent_unordered_multiset& m) |
Swaps contents of *this and m. |