MySQL 9.6.0
Source Code Documentation
mysql::sets::Nested_container< Storage_tp > Class Template Reference

Represents the subset of a Cartesian product "L x R" of two sets, using a map data structure that maps elements of type L to containers holding values of type R. More...

#include <nested_container.h>

Inheritance diagram for mysql::sets::Nested_container< Storage_tp >:
[legend]

Public Types

using Storage_t = Storage_tp
 
using This_t = Nested_container< Storage_t >
 
using Base_t = Basic_nested_container_wrapper< Nested_container< Storage_tp >, Storage_tp >
 
using Set_category_t = Nested_set_category_tag
 
using Memory_resource_t = mysql::allocators::Memory_resource
 
using Return_status_t = mysql::utils::Return_status
 
- Public Types inherited from mysql::containers::Basic_container_wrapper< Self_tp, Wrapped_tp, mysql::utils::Shall_catch::no >
using Wrapped_t = Wrapped_tp
 
- Public Types inherited from mysql::sets::detail::Nested_set_interface< Self_tp, Iterator_tp, Const_iterator_tp, Set_traits_tp >
using Iterator_t = Iterator_tp
 
using Const_iterator_t = Const_iterator_tp
 
using Set_category_t = Nested_set_category_tag
 
using Iterator_value_t = mysql::ranges::Iterator_value_type< Iterator_t >
 
using Set_traits_t = Set_traits_tp
 
using Key_traits_t = typename Set_traits_t::Key_traits_t
 
using Key_t = typename Key_traits_t::Element_t
 
using Mapped_category_t = typename Set_traits_t::Mapped_category_t
 
using Mapped_traits_t = typename Set_traits_t::Mapped_traits_t
 
using Mapped_t = typename Iterator_value_t::second_type
 

Public Member Functions

template<class... Args_t>
requires mysql::meta::Not_decayed<This_t, Args_t...>
 Nested_container (Args_t &&...args) noexcept
 Construct a new, empty Nested_container. More...
 
auto & storage () noexcept
 Return non-const reference to the underlying storage. More...
 
const auto & storage () const noexcept
 Return const reference to the underlying storage. More...
 
Const_iterator_t find (const Key_t &key) const noexcept
 Return const iterator to the pair having the given key in the first component, or end() if the key is not in the set. More...
 
Iterator_t find (const Key_t &key) noexcept
 Return iterator to the pair having the given key in the first component, or end() if the key is not in the set. More...
 
Const_iterator_t find (Const_iterator_t &cursor, const Key_t &key) const noexcept
 Return const iterator to the pair having the given key in the first component, or end() if the key is not in the set. More...
 
Iterator_t find (Iterator_t &cursor, const Key_t &key) noexcept
 Return iterator to the pair having the given key in the first component, or end() if the key is not in the set. More...
 
template<class... Mapped_args_t>
Return_status_t insert (const Key_t &key, Mapped_args_t &&...mapped_args) noexcept
 Insert the given element (inplace union). More...
 
Return_status_t remove (const Key_t &key, const auto &...value) noexcept
 Remove the given element from the set, if it is there. More...
 
template<class... Mapped_args_t>
auto inplace_union (const Key_t &key, Mapped_args_t &&...mapped_args) noexcept
 Insert the given set (inplace union). More...
 
template<class... Mapped_args_t>
auto inplace_union (Iterator_t &cursor, const Key_t &key, Mapped_args_t &&...mapped_args) noexcept
 Insert the given set (inplace union), reading and updating the given cursor. More...
 
template<Is_nested_set_over_traits_unqualified< Set_traits_t > Other_set_t>
auto inplace_union (Other_set_t &&other_set) noexcept
 Inplace-insert the given set (inplace union) into this container. More...
 
void inplace_subtract (const Key_t &key) noexcept
 Inplace-remove the given key and associated mapped set. More...
 
template<class... Mapped_args_t>
auto inplace_subtract (const Key_t &key, Mapped_args_t &&...mapped_args) noexcept
 Inplace-remove the given mapped set from the mapped set associated with the given key. More...
 
template<class... Mapped_args_t>
auto inplace_subtract (Iterator_t &cursor, const Key_t &key, Mapped_args_t &&...mapped_args) noexcept
 Inplace-remove the given mapped set from the mapped set associated with the given key, reading and updating the given cursor. More...
 
template<Is_nested_set_over_traits_unqualified< Set_traits_t > Other_set_t>
auto inplace_subtract (Other_set_t &&other_set) noexcept
 Inplace-remove the given set from this container. More...
 
void inplace_intersect (const Key_t &key) noexcept
 Inplace-remove all value pairs, except the one for the given key. More...
 
template<class... Mapped_args_t>
auto inplace_intersect (const Key_t &key, Mapped_args_t &&...mapped_args) noexcept
 Inplace-remove all value pairs, except the one for the given key, and inplace-intersect the mapped container for the given key with the given mapped set. More...
 
template<Is_nested_set_over_traits_unqualified< Set_traits_t > Other_set_t>
auto inplace_intersect (Other_set_t &&other_set) noexcept
 Inplace-intersect this set with the given set. More...
 
- Public Member Functions inherited from mysql::sets::Basic_nested_container_wrapper< Nested_container< Storage_tp >, Storage_tp >
 Basic_nested_container_wrapper (Args_t &&...args) noexcept(noexcept(Wrapper_base_t(std::forward< Args_t >(args)...)))
 
- Public Member Functions inherited from mysql::sets::Basic_set_container_wrapper< Self_tp, Wrapped_tp, shall_catch_tp >
template<class... Args_t>
 Basic_set_container_wrapper (Args_t &&...args)
 
template<class Source_t >
requires Can_donate_set<decltype(std::declval<Source_t &&>().wrapped()), Wrapped_tp>
void assign (Source_t &&source)
 Enable move-assign from any Basic_set_container_wrapper for a compatible set type (not necessarily for a derived class). More...
 
template<std::input_iterator First_iterator_t, std::sentinel_for< First_iterator_t > Sentinel_t>
requires requires(Wrapped_t w, First_iterator_t f, Sentinel_t s) { w.assign(f, s); }
auto assign (const First_iterator_t &first, const Sentinel_t &last) noexcept(shall_catch==mysql::utils::Shall_catch::yes||noexcept(std::declval< Wrapped_t >().assign(first, last)))
 Assign a range defined by the two iterators to the wrapped object. More...
 
template<class Other_t >
auto assign (const Other_t &other) noexcept(shall_catch==mysql::utils::Shall_catch::yes||noexcept(std::declval< Self_t >().assign(other.begin(), other.end())))
 Copy-assign the other object to the wrapped object. More...
 
void assign (Self_t &&other) noexcept
 Move-assign the other object to the wrapped object. More...
 
- Public Member Functions inherited from mysql::containers::Basic_container_wrapper< Self_tp, Wrapped_tp, mysql::utils::Shall_catch::no >
 Basic_container_wrapper (Args_t &&...args) noexcept(noexcept(Wrapped_t(std::forward< Args_t >(args)...)))
 Constructor that delegates all parameters to the constructor of the wrapped class. More...
 
auto assign (const First_iterator_t &first, const Sentinel_t &last) noexcept(shall_catch==mysql::utils::Shall_catch::yes||noexcept(std::declval< Wrapped_t >().assign(first, last)))
 Assign a range defined by the two iterators to the wrapped object. More...
 
auto assign (const Other_t &other) noexcept(shall_catch==mysql::utils::Shall_catch::yes||noexcept(std::declval< Self_t >().assign(other.begin(), other.end())))
 Copy-assign the other object to the wrapped object. More...
 
void assign (Self_t &&other) noexcept
 Move-assign the other object to the wrapped object. More...
 
void clear () noexcept
 Clear the wrapped object. More...
 
auto get_memory_resource () const noexcept
 Return the memory resource used by the wrapped object. More...
 
auto get_allocator () const noexcept
 Return the allocator used by the wrapped object. More...
 
auto begin () noexcept
 
auto begin () const noexcept
 
auto end () noexcept
 
auto end () const noexcept
 
auto empty () const noexcept
 
auto size () const noexcept
 
- Public Member Functions inherited from mysql::ranges::Collection_interface< Self_tp >
constexpr auto cbegin () const
 Return constant iterator to the beginning. More...
 
constexpr auto cend () const
 Return constant iterator to the end. More...
 
constexpr auto rbegin ()
 Return reverse iterator to the beginning. More...
 
constexpr auto rend ()
 Return reverse iterator to the end. More...
 
constexpr auto rbegin () const
 Return const reverse iterator to the beginning. More...
 
constexpr auto rend () const
 Return const reverse iterator to the end. More...
 
constexpr auto crbegin () const
 Return const reverse iterator to the beginning. More...
 
constexpr auto crend () const
 Return const reverse iterator to the end. More...
 
constexpr bool empty () const
 Return true if the range is empty, i.e., begin() == end(). More...
 
constexpr operator bool () const
 Return true if the range is non-empty, i.e., begin() != end(). More...
 
constexpr bool operator! () const
 Return true if the range is empty, i.e., begin() == end(). More...
 
constexpr auto size () const
 Return the number of elements in this view, unsigned (size_t), by computing std::ranges::distance(begin, end) More...
 
constexpr auto ssize () const
 Return the number of elements in this view, signed (ptrdiff_t). More...
 
constexpr decltype(auto) front () const
 Return the first element. More...
 
constexpr decltype(auto) back () const
 Return the last element. Enabled if we have bidirectional iterators. More...
 
constexpr decltype(auto) operator[] (std::ptrdiff_t n)
 Return the n'th element, possibly mutable. More...
 
constexpr decltype(auto) operator[] (std::ptrdiff_t n) const
 Return the n'th element, const. More...
 
constexpr auto * data ()
 Return pointer to underlying contiguous memory. More...
 
constexpr auto * data () const
 Return const pointer to underlying contiguous memory. More...
 
- Public Member Functions inherited from mysql::sets::detail::Nested_set_interface< Self_tp, Iterator_tp, Const_iterator_tp, Set_traits_tp >
auto & operator[] (const Key_t &key) noexcept
 Return non-const reference to the mapped Set for the given key. More...
 
const auto & operator[] (const Key_t &key) const noexcept
 Return const reference to the mapped Set for the given key. More...
 

Static Public Attributes

static constexpr Return_status_t return_ok = Return_status_t::ok
 

Private Member Functions

template<class... Mapped_args_t>
auto insert_or_union (const auto &func, const auto &opt_it, Mapped_args_t &&...mapped_args) noexcept
 Common implementation for insert and several of the inplace_union operations: it performs the insertion operation, given an iterator to the key-value pair and a mapped set. More...
 
void advance_and_erase_if_empty (Iterator_t &iterator) noexcept
 Helper that will erase the value pair that the iterator points to if it is empty, and, regardless if it erased or not, make the iterator point to the next element. More...
 

Additional Inherited Members

- Protected Member Functions inherited from mysql::containers::Basic_container_wrapper< Self_tp, Wrapped_tp, mysql::utils::Shall_catch::no >
auto & wrapped () &noexcept
 
const auto & wrapped () const &noexcept
 
auto && wrapped () &&noexcept
 

Detailed Description

template<Is_nested_storage Storage_tp>
class mysql::sets::Nested_container< Storage_tp >

Represents the subset of a Cartesian product "L x R" of two sets, using a map data structure that maps elements of type L to containers holding values of type R.

This never throws exceptions. All member functions that can fail, return a status and have the [[nodiscard]] attribute.

Template Parameters
Storage_tpUnderlying storage

Member Typedef Documentation

◆ Base_t

template<Is_nested_storage Storage_tp>
using mysql::sets::Nested_container< Storage_tp >::Base_t = Basic_nested_container_wrapper<Nested_container<Storage_tp>, Storage_tp>

◆ Memory_resource_t

template<Is_nested_storage Storage_tp>
using mysql::sets::Nested_container< Storage_tp >::Memory_resource_t = mysql::allocators::Memory_resource

◆ Return_status_t

template<Is_nested_storage Storage_tp>
using mysql::sets::Nested_container< Storage_tp >::Return_status_t = mysql::utils::Return_status

◆ Set_category_t

template<Is_nested_storage Storage_tp>
using mysql::sets::Nested_container< Storage_tp >::Set_category_t = Nested_set_category_tag

◆ Storage_t

template<Is_nested_storage Storage_tp>
using mysql::sets::Nested_container< Storage_tp >::Storage_t = Storage_tp

◆ This_t

template<Is_nested_storage Storage_tp>
using mysql::sets::Nested_container< Storage_tp >::This_t = Nested_container<Storage_t>

Constructor & Destructor Documentation

◆ Nested_container()

template<Is_nested_storage Storage_tp>
template<class... Args_t>
requires mysql::meta::Not_decayed<This_t, Args_t...>
mysql::sets::Nested_container< Storage_tp >::Nested_container ( Args_t &&...  args)
inlineexplicitnoexcept

Construct a new, empty Nested_container.

Parameters
argsany arguments are passed to the base class.

Member Function Documentation

◆ advance_and_erase_if_empty()

template<Is_nested_storage Storage_tp>
void mysql::sets::Nested_container< Storage_tp >::advance_and_erase_if_empty ( Iterator_t iterator)
inlineprivatenoexcept

Helper that will erase the value pair that the iterator points to if it is empty, and, regardless if it erased or not, make the iterator point to the next element.

This will point to the next element even if an erase operation was performed which invalidated iterators.

Parameters
iteratorIterator to operate on.

◆ find() [1/4]

template<Is_nested_storage Storage_tp>
Const_iterator_t mysql::sets::Nested_container< Storage_tp >::find ( const Key_t key) const
inlinenoexcept

Return const iterator to the pair having the given key in the first component, or end() if the key is not in the set.

Parameters
keyKey to look for.

◆ find() [2/4]

template<Is_nested_storage Storage_tp>
Iterator_t mysql::sets::Nested_container< Storage_tp >::find ( const Key_t key)
inlinenoexcept

Return iterator to the pair having the given key in the first component, or end() if the key is not in the set.

Parameters
keyKey to look for.

◆ find() [3/4]

template<Is_nested_storage Storage_tp>
Const_iterator_t mysql::sets::Nested_container< Storage_tp >::find ( Const_iterator_t cursor,
const Key_t key 
) const
inlinenoexcept

Return const iterator to the pair having the given key in the first component, or end() if the key is not in the set.

Parameters
keyKey to look for.
[in,out]cursorIterator hint. If this is greater than the lower bound for key, the behavior is undefined. It will be updated to the upper bound for the key. Thus, it is suitable to use in successive calls to this function with increasing keys. This is not nodiscard because someone may want to only advance the cursor.

◆ find() [4/4]

template<Is_nested_storage Storage_tp>
Iterator_t mysql::sets::Nested_container< Storage_tp >::find ( Iterator_t cursor,
const Key_t key 
)
inlinenoexcept

Return iterator to the pair having the given key in the first component, or end() if the key is not in the set.

Parameters
keyKey to look for.
[in,out]cursorIterator hint. If this is greater than the lower bound for key, the behavior is undefined. It will be updated to the upper bound for the key. Thus, it is suitable to use in successive calls to this function with increasing keys. This is not nodiscard because someone may want to only advance the cursor.

◆ inplace_intersect() [1/3]

template<Is_nested_storage Storage_tp>
void mysql::sets::Nested_container< Storage_tp >::inplace_intersect ( const Key_t key)
inlinenoexcept

Inplace-remove all value pairs, except the one for the given key.

Parameters
keyKey to keep.

This operation cannot fail.

◆ inplace_intersect() [2/3]

template<Is_nested_storage Storage_tp>
template<class... Mapped_args_t>
auto mysql::sets::Nested_container< Storage_tp >::inplace_intersect ( const Key_t key,
Mapped_args_t &&...  mapped_args 
)
inlinenoexcept

Inplace-remove all value pairs, except the one for the given key, and inplace-intersect the mapped container for the given key with the given mapped set.

Parameters
keyKey to keep.
mapped_argsArguments to pass to inplace_intersect on the mapped set.
Returns
Return_status::ok if the operation succeeds, or Return_status::error if an out-of-memory condition occurs. This can happen if the inplace_intersect operation of the mapped container fails. This may leave the container as a subset of the previous set and a superset of the intersection.

◆ inplace_intersect() [3/3]

template<Is_nested_storage Storage_tp>
template<Is_nested_set_over_traits_unqualified< Set_traits_t > Other_set_t>
auto mysql::sets::Nested_container< Storage_tp >::inplace_intersect ( Other_set_t &&  other_set)
inlinenoexcept

Inplace-intersect this set with the given set.

If other_set is an rvalue reference, any time this function makes a recursive call to inplace_intersect on the mapped sets, it will pass an rvalue reference to a mapped set in other_set. This possibly enables stealing, if allowed by the types and allocators of those sets. If stealing is possible on all nesting levels, this cannot fail.

Parameters
other_setSet to intersect with.
Returns
Return_status::ok on success, or Return_status::error if an out-of-memory condition occurred. This can happen if the inplace_intersect member of the mapped set fails. This may leave the container as a subset of the previous set and a superset of the intersection.

◆ inplace_subtract() [1/4]

template<Is_nested_storage Storage_tp>
void mysql::sets::Nested_container< Storage_tp >::inplace_subtract ( const Key_t key)
inlinenoexcept

Inplace-remove the given key and associated mapped set.

Parameters
keyKey to remove.

This operation cannot fail.

◆ inplace_subtract() [2/4]

template<Is_nested_storage Storage_tp>
template<class... Mapped_args_t>
auto mysql::sets::Nested_container< Storage_tp >::inplace_subtract ( const Key_t key,
Mapped_args_t &&...  mapped_args 
)
inlinenoexcept

Inplace-remove the given mapped set from the mapped set associated with the given key.

Parameters
keyKey to find.
mapped_argsArguments passed to inplace_subtract of the mapped set.
Returns
Return_status::ok on success, or Return_status::error on out-of-memory error. This can occur if the inplace_subtract member function of the mapped container type can fail. It may leave this set as a subset of the old set and a superset of the difference set.

◆ inplace_subtract() [3/4]

template<Is_nested_storage Storage_tp>
template<class... Mapped_args_t>
auto mysql::sets::Nested_container< Storage_tp >::inplace_subtract ( Iterator_t cursor,
const Key_t key,
Mapped_args_t &&...  mapped_args 
)
inlinenoexcept

Inplace-remove the given mapped set from the mapped set associated with the given key, reading and updating the given cursor.

Parameters
[in,out]cursorHint for the position of the key. If this is greater than the lower bound for key, the behavior is undefined. It will be updated to point to the element following key, which makes it good to reuse for future calls to this function, with keys following this one.
keyKey to find.
mapped_argsArguments passed to inplace_subtract of the mapped set.
Returns
Return_status::ok on success, or Return_status::error on out-of-memory error. This can occur if the inplace_subtract member function of the mapped container type can fail. It may leave this set as a subset of the old set and a superset of the difference set.

◆ inplace_subtract() [4/4]

template<Is_nested_storage Storage_tp>
template<Is_nested_set_over_traits_unqualified< Set_traits_t > Other_set_t>
auto mysql::sets::Nested_container< Storage_tp >::inplace_subtract ( Other_set_t &&  other_set)
inlinenoexcept

Inplace-remove the given set from this container.

This iterates over value pairs of this container and value pairs of the other set, where the key part of the two pairs are equal. In each step, it invokes inplace_subtract on the mapped container, passing the mapped other set as parameter. The number of iterations over value pairs is bounded by min(this->size, other_set.size()).

If other_set is an rvalue reference, any time this function makes a recursive call to inplace_subtract on the mapped sets, it will pass an rvalue reference to a mapped set in other_set. This possibly enables stealing, if allowed by the types and allocators of those sets. If stealing is possible on all nesting levels, this cannot fail.

Parameters
other_setSet to subtract
Returns
Return_status::ok on success, or Return_status::error if an out-of-memory condition occurred. This can happen if the inplace_subtract member of the mapped set fails. This may leave the container as a subset of the previous set and a superset of the difference.

◆ inplace_union() [1/3]

template<Is_nested_storage Storage_tp>
template<class... Mapped_args_t>
auto mysql::sets::Nested_container< Storage_tp >::inplace_union ( const Key_t key,
Mapped_args_t &&...  mapped_args 
)
inlinenoexcept

Insert the given set (inplace union).

This will create the value pair with the given key and an empty mapped container if it does not exist. Then it will invoke the inplace_union member function of the mapped container.

Parameters
keyKey of the element to insert.
mapped_argsArguments passed to the inplace_union member function of the mapped container.
Returns
Return_status::ok on success, or Return_status::error if an out-of-memory condition occurred. This can either when inserting into the storage for this object, or when invoking inplace_union for the mapped container. This may leave the container as a superset of the previous set and a subset of the union.

◆ inplace_union() [2/3]

template<Is_nested_storage Storage_tp>
template<class... Mapped_args_t>
auto mysql::sets::Nested_container< Storage_tp >::inplace_union ( Iterator_t cursor,
const Key_t key,
Mapped_args_t &&...  mapped_args 
)
inlinenoexcept

Insert the given set (inplace union), reading and updating the given cursor.

This will create the value pair with the given key and an empty mapped container if it does not exist. Then it will invoke the inplace_union member function of the mapped container.

Parameters
[in,out]cursorHint for the insertion position. If this is greater than the lower bound for key, the behavior is undefined. It will be updated to the element after the inserted one, which makes it good to reuse for future calls to this function, with keys following this one.
keyKey of the element to insert.
mapped_argsArguments passed to the inplace_union member function of the mapped container.
Returns
Return_status::ok on success, or Return_status::error if an out-of-memory condition occurred. This can either when inserting into the storage for this object, or when invoking inplace_union for the mapped container. This may leave the container as a superset of the previous set and a subset of the union.

◆ inplace_union() [3/3]

template<Is_nested_storage Storage_tp>
template<Is_nested_set_over_traits_unqualified< Set_traits_t > Other_set_t>
auto mysql::sets::Nested_container< Storage_tp >::inplace_union ( Other_set_t &&  other_set)
inlinenoexcept

Inplace-insert the given set (inplace union) into this container.

This will iterate over the input set and repeatedly invoke inplace_union(cursor, key, mapped).

If other_set is an rvalue reference, and its allocator compares equal with this Nested_container's allocator, and the set types satisfy Can_donate_set_elements, this steals elements from other and does not allocate elements in the Nested_set. The same applies on all levels of nested containers, i.e., the mapped sets may steal if their allocators compare equal and their types satisfy Can_donate_set_elements; and so on on all nesting levels. If stealing is possible on all levels, this cannot fail.

Parameters
other_setArguments passed to the inplace_union member function of the mapped container.
Returns
Return_status::ok on success, or Return_status::error if an out-of-memory condition occurred, either when inserting into the storage for this object, or when invoking inplace_union for the mapped container. This may leave the container as a superset of the previous set and a subset of the union.

◆ insert()

template<Is_nested_storage Storage_tp>
template<class... Mapped_args_t>
Return_status_t mysql::sets::Nested_container< Storage_tp >::insert ( const Key_t key,
Mapped_args_t &&...  mapped_args 
)
inlinenoexcept

Insert the given element (inplace union).

This will create the value pair with the given key and an empty mapped container if it does not exist. Then it will invoke the insert member function of the mapped container.

Parameters
keyKey of the element to insert.
mapped_argsArguments passed to the insert member function of the mapped container.
Returns
Return_status::ok on success, or Return_status::error if an out-of-memory condition occurred. This can either when inserting into the storage for this object, or when inserting into the mapped container. On error, the container is left unchanged: in particular, if an error occurred after inserting the value pair into the map, the value pair is removed again.

◆ insert_or_union()

template<Is_nested_storage Storage_tp>
template<class... Mapped_args_t>
auto mysql::sets::Nested_container< Storage_tp >::insert_or_union ( const auto &  func,
const auto &  opt_it,
Mapped_args_t &&...  mapped_args 
)
inlineprivatenoexcept

Common implementation for insert and several of the inplace_union operations: it performs the insertion operation, given an iterator to the key-value pair and a mapped set.

Template Parameters
Mapped_args_tType of parameters passed to the lambda.
Parameters
funcCallable that will perform the insert or inplace_union operation in the mapped set. It will be passed the mapped set, followed by the arguments in mapped_args.
opt_itstd::optional that may hold an iterator to the value pair on which the insert or inplace_union operation should operate. If this does not hold a value, this function returns Return_status::error immediately; otherwise it attempts to insert into the mapped container it points to.
mapped_argsParameters to pass to func.
Returns
Return_status::ok on success; Return_status::error if either opt_it does not hold a value, or func fails.

◆ remove()

template<Is_nested_storage Storage_tp>
Return_status_t mysql::sets::Nested_container< Storage_tp >::remove ( const Key_t key,
const auto &...  value 
)
inlinenoexcept

Remove the given element from the set, if it is there.

This will lookup the value pair in this set. If the key was found, remove the element from the mapped container by invoking its remove member function. If the resulting mapped container becomes empty, the value pair is removed from this container.

Parameters
keyKey of the element to insert.
valueArguments passed to the remove member function of the mapped container.
Returns
Return_status::ok on success, or Return_status::error if an out-of-memory condition occurred. This can happen if removing from the mapped container required an allocation, for example, to split an interval. On error, the container is left unchanged.

◆ storage() [1/2]

template<Is_nested_storage Storage_tp>
const auto & mysql::sets::Nested_container< Storage_tp >::storage ( ) const
inlinenoexcept

Return const reference to the underlying storage.

◆ storage() [2/2]

template<Is_nested_storage Storage_tp>
auto & mysql::sets::Nested_container< Storage_tp >::storage ( )
inlinenoexcept

Return non-const reference to the underlying storage.

Member Data Documentation

◆ return_ok

template<Is_nested_storage Storage_tp>
constexpr Return_status_t mysql::sets::Nested_container< Storage_tp >::return_ok = Return_status_t::ok
staticconstexpr

The documentation for this class was generated from the following file: