|
pstore2
|
A wrapper for the sparse_array<> type which is specialized for indices of type section_kind. More...
#include <section_sparray.hpp>
Classes | |
| class | indices |
| A container which can be used to access and iterate over the available index values in the sparse array. More... | |
Public Member Functions | |
| template<typename IndexIterator , typename = typename std::enable_if_t< is_section_kind_iterator<IndexIterator> ()>> | |
| constexpr | section_sparray (IndexIterator first, IndexIterator last) |
| Constructs a sparse array whose available indices are defined by the iterator range from [first,last) and whose corresponding values are default constructed. More... | |
| constexpr std::size_t | size_bytes () const |
| Returns the number of bytes of storage that are being used by this array instance. | |
| indices | get_indices () const noexcept |
Element access | |
| constexpr value_type & | operator[] (section_kind k) noexcept |
| constexpr value_type const & | operator[] (section_kind k) const noexcept |
| constexpr reference | front () noexcept |
| Returns the value associated with the first section-kind index in the container. | |
| constexpr const_reference | front () const noexcept |
| Returns the value associated with the first section-kind index in the container. | |
| constexpr reference | back () noexcept |
| Returns the value associated with the last section-kind index in the container. | |
| constexpr const_reference | back () const noexcept |
| Returns the value associated with the last section-kind index in the container. | |
Iterators | |
| iterator | begin () |
| Returns an iterator to the beginning of the container. | |
| const_iterator | begin () const |
| const_iterator | cbegin () const |
| iterator | end () |
| Returns an iterator to the end of the container. | |
| const_iterator | end () const |
| const_iterator | cend () const |
Capacity | |
| constexpr bool | empty () const noexcept |
| constexpr size_type | size () const noexcept |
| constexpr bool | has_index (section_kind pos) const noexcept |
Returns true if the sparse array has an index pos. More... | |
Static Public Member Functions | |
| static constexpr std::size_t | size_bytes (std::size_t members) noexcept |
Returns the number of bytes of storage that are required for an instance of section_sparray<T> where members is the number of available section-kinds. More... | |
A wrapper for the sparse_array<> type which is specialized for indices of type section_kind.
| constexpr pstore::repo::section_sparray< T >::section_sparray | ( | IndexIterator | first, |
| IndexIterator | last | ||
| ) |
Constructs a sparse array whose available indices are defined by the iterator range from [first,last) and whose corresponding values are default constructed.
|
inlinenoexcept |
Returns true if the sparse array has an index pos.
| pos | The section kind to be tested. |
pos section; false otherwise.
|
staticnoexcept |
Returns the number of bytes of storage that are required for an instance of section_sparray<T> where members is the number of available section-kinds.
1.8.13