kblib
0.2.3
General utilities library for modern C++
|
#include <kblib/direct_map.h>
Public Types | |
using | key_type = Key |
using | mapped_type = T |
using | value_type = std::pair< const Key, T > |
using | size_type = std::size_t |
using | difference_type = std::ptrdiff_t |
using | reference = value_type & |
using | const_reference = const value_type & |
using | pointer = value_type * |
using | const_pointer = const value_type * |
using | iterator = iter< value_type > |
using | const_iterator = iter< const value_type > |
using | reverse_iterator = std::reverse_iterator< iterator > |
using | const_reverse_iterator = std::reverse_iterator< const_iterator > |
Public Member Functions | |
constexpr | direct_map () noexcept=default |
template<typename InputIt > | |
constexpr | direct_map (InputIt first, InputIt last) |
constexpr | direct_map (const direct_map &other) |
constexpr | direct_map (direct_map &&other) noexcept |
constexpr | direct_map (std::initializer_list< value_type > init) |
KBLIB_CXX20 (constexpr) ~direct_map() | |
constexpr auto | operator= (const direct_map &other) -> direct_map & |
constexpr auto | operator= (direct_map &&other) noexcept -> direct_map &=default |
constexpr auto | operator= (std::initializer_list< value_type > init) -> direct_map & |
constexpr KBLIB_NODISCARD auto | at (Key key) &-> T & |
constexpr KBLIB_NODISCARD auto | at (Key key) &&-> T && |
constexpr KBLIB_NODISCARD auto | at (Key key) const &-> const T & |
constexpr KBLIB_NODISCARD auto | at (Key key) const &&-> const T && |
constexpr KBLIB_NODISCARD T & | operator[] (Key key) noexcept(std::is_nothrow_default_constructible< T >::value) |
constexpr KBLIB_NODISCARD auto | begin () &noexcept -> iterator |
constexpr KBLIB_NODISCARD auto | begin () const &noexcept -> const_iterator |
constexpr KBLIB_NODISCARD auto | cbegin () const &noexcept -> const_iterator |
constexpr KBLIB_NODISCARD auto | end () &noexcept -> iterator |
constexpr KBLIB_NODISCARD auto | end () const &noexcept -> const_iterator |
constexpr KBLIB_NODISCARD auto | cend () const &noexcept -> const_iterator |
constexpr KBLIB_NODISCARD auto | rbegin () &noexcept -> auto |
constexpr KBLIB_NODISCARD auto | rbegin () const &noexcept -> auto |
constexpr KBLIB_NODISCARD auto | crbegin () const &noexcept -> auto |
constexpr KBLIB_NODISCARD auto | rend () &noexcept -> auto |
constexpr KBLIB_NODISCARD auto | rend () const &noexcept -> auto |
constexpr KBLIB_NODISCARD auto | crend () const &noexcept -> auto |
constexpr KBLIB_NODISCARD auto | empty () const &noexcept -> bool |
constexpr KBLIB_NODISCARD auto | size () const &noexcept -> std::size_t |
constexpr KBLIB_NODISCARD auto | ssize () const &noexcept -> std::ptrdiff_t |
constexpr auto | clear () noexcept -> void |
constexpr auto | insert (const value_type &value) -> std::pair< iterator, bool > |
template<typename U > | |
constexpr auto | insert (U &&value) -> enable_if_t< std::is_constructible< value_type, U && >::value, std::pair< iterator, bool >> |
constexpr auto | insert (value_type &&value) -> std::pair< iterator, bool > |
template<typename U > | |
constexpr auto | insert_or_assign (Key key, U &&value) -> std::pair< iterator, bool > |
template<typename... Args> | |
constexpr auto | try_emplace (Key key, Args &&... args) -> std::pair< iterator, bool > |
constexpr auto | erase (iterator pos) noexcept -> iterator |
constexpr auto | erase (const_iterator pos) noexcept -> iterator |
constexpr auto | erase (iterator first, iterator last) noexcept -> iterator |
constexpr auto | erase (Key key) noexcept -> std::size_t |
constexpr auto | swap (direct_map &other) noexcept -> void |
constexpr KBLIB_NODISCARD auto | contains (Key key) const noexcept -> bool |
constexpr KBLIB_NODISCARD auto | count (Key key) const noexcept -> std::size_t |
constexpr KBLIB_NODISCARD auto | find (Key key) &noexcept -> iterator |
constexpr KBLIB_NODISCARD auto | find (Key key) const &noexcept -> const_iterator |
constexpr KBLIB_NODISCARD auto | equal_range (Key key) &noexcept -> std::pair< iterator, iterator > |
constexpr KBLIB_NODISCARD auto | equal_range (Key key) const &noexcept -> std::pair< const_iterator, const_iterator > |
constexpr KBLIB_NODISCARD auto | lower_bound (Key key) &noexcept -> iterator |
constexpr KBLIB_NODISCARD auto | lower_bound (Key key) const &noexcept -> const_iterator |
constexpr KBLIB_NODISCARD auto | upper_bound (Key key) &noexcept -> iterator |
constexpr KBLIB_NODISCARD auto | upper_bound (Key key) const &noexcept -> const_iterator |
Static Public Member Functions | |
constexpr static KBLIB_NODISCARD auto | max_size () noexcept -> std::size_t |
constexpr static KBLIB_NODISCARD auto | min () noexcept -> Key |
constexpr static KBLIB_NODISCARD auto | max () noexcept -> Key |
constexpr static KBLIB_NODISCARD auto | index (Key key) noexcept -> std::ptrdiff_t |
constexpr static KBLIB_NODISCARD auto | uindex (Key key) noexcept -> std::size_t |
constexpr static KBLIB_NODISCARD auto | to_key (std::ptrdiff_t i) noexcept -> Key |
Friends | |
KBLIB_NODISCARD constexpr friend auto | operator== (const direct_map &l, const direct_map &r) noexcept(noexcept(std::declval< T & >()==std::declval< T & >())) -> bool |
KBLIB_NODISCARD constexpr friend auto | operator!= (const direct_map &l, const direct_map &r) noexcept(noexcept(std::declval< T & >()==std::declval< T & >())) -> bool |
KBLIB_NODISCARD constexpr friend auto | operator< (const direct_map &l, const direct_map &r) noexcept(noexcept(std::declval< T & >(), std::declval< T & >())) -> bool |
KBLIB_NODISCARD constexpr friend auto | operator> (const direct_map &l, const direct_map &r) noexcept(noexcept(std::declval< T & >(), std::declval< T & >())) -> bool |
KBLIB_NODISCARD constexpr friend auto | operator<= (const direct_map &l, const direct_map &r) noexcept(noexcept(std::declval< T & >(), std::declval< T & >())) -> bool |
KBLIB_NODISCARD constexpr friend auto | operator>= (const direct_map &l, const direct_map &r) noexcept(noexcept(std::declval< T & >(), std::declval< T & >())) -> bool |
Definition at line 125 of file direct_map.h.
using kblib::direct_map< Key, T, allocator >::const_iterator = iter<const value_type> |
Definition at line 231 of file direct_map.h.
using kblib::direct_map< Key, T, allocator >::const_pointer = const value_type* |
Definition at line 137 of file direct_map.h.
using kblib::direct_map< Key, T, allocator >::const_reference = const value_type& |
Definition at line 135 of file direct_map.h.
using kblib::direct_map< Key, T, allocator >::const_reverse_iterator = std::reverse_iterator<const_iterator> |
Definition at line 233 of file direct_map.h.
using kblib::direct_map< Key, T, allocator >::difference_type = std::ptrdiff_t |
Definition at line 132 of file direct_map.h.
using kblib::direct_map< Key, T, allocator >::iterator = iter<value_type> |
Definition at line 230 of file direct_map.h.
using kblib::direct_map< Key, T, allocator >::key_type = Key |
Definition at line 128 of file direct_map.h.
using kblib::direct_map< Key, T, allocator >::mapped_type = T |
Definition at line 129 of file direct_map.h.
using kblib::direct_map< Key, T, allocator >::pointer = value_type* |
Definition at line 136 of file direct_map.h.
using kblib::direct_map< Key, T, allocator >::reference = value_type& |
Definition at line 134 of file direct_map.h.
using kblib::direct_map< Key, T, allocator >::reverse_iterator = std::reverse_iterator<iterator> |
Definition at line 232 of file direct_map.h.
using kblib::direct_map< Key, T, allocator >::size_type = std::size_t |
Definition at line 131 of file direct_map.h.
using kblib::direct_map< Key, T, allocator >::value_type = std::pair<const Key, T> |
Definition at line 130 of file direct_map.h.
|
constexprdefaultnoexcept |
|
inlineconstexpr |
Definition at line 238 of file direct_map.h.
|
inlineconstexpr |
Definition at line 245 of file direct_map.h.
|
inlineconstexprnoexcept |
Definition at line 256 of file direct_map.h.
|
inlineconstexpr |
Definition at line 260 of file direct_map.h.
|
inlineconstexpr |
Definition at line 301 of file direct_map.h.
|
inlineconstexpr |
Definition at line 294 of file direct_map.h.
|
inlineconstexpr |
Definition at line 315 of file direct_map.h.
|
inlineconstexpr |
Definition at line 308 of file direct_map.h.
|
inlineconstexprnoexcept |
Definition at line 328 of file direct_map.h.
|
inlineconstexprnoexcept |
Definition at line 331 of file direct_map.h.
|
inlineconstexprnoexcept |
Definition at line 334 of file direct_map.h.
|
inlineconstexprnoexcept |
Definition at line 352 of file direct_map.h.
|
inlineconstexprnoexcept |
Definition at line 391 of file direct_map.h.
|
inlineconstexprnoexcept |
Definition at line 493 of file direct_map.h.
|
inlineconstexprnoexcept |
Definition at line 496 of file direct_map.h.
|
inlineconstexprnoexcept |
Definition at line 362 of file direct_map.h.
|
inlineconstexprnoexcept |
Definition at line 372 of file direct_map.h.
|
inlineconstexprnoexcept |
Definition at line 376 of file direct_map.h.
|
inlineconstexprnoexcept |
Definition at line 346 of file direct_map.h.
|
inlineconstexprnoexcept |
Definition at line 349 of file direct_map.h.
|
inlineconstexprnoexcept |
Definition at line 510 of file direct_map.h.
|
inlineconstexprnoexcept |
Definition at line 514 of file direct_map.h.
|
inlineconstexprnoexcept |
Definition at line 458 of file direct_map.h.
|
inlineconstexprnoexcept |
Definition at line 465 of file direct_map.h.
|
inlineconstexprnoexcept |
Definition at line 452 of file direct_map.h.
|
inlineconstexprnoexcept |
Definition at line 476 of file direct_map.h.
|
inlineconstexprnoexcept |
Definition at line 500 of file direct_map.h.
|
inlineconstexprnoexcept |
Definition at line 504 of file direct_map.h.
|
inlinestaticconstexprnoexcept |
Definition at line 616 of file direct_map.h.
|
inlineconstexpr |
Definition at line 402 of file direct_map.h.
|
inlineconstexpr |
Definition at line 411 of file direct_map.h.
|
inlineconstexpr |
Definition at line 421 of file direct_map.h.
|
inlineconstexpr |
Definition at line 431 of file direct_map.h.
|
inline |
Definition at line 266 of file direct_map.h.
|
inlineconstexprnoexcept |
Definition at line 519 of file direct_map.h.
|
inlineconstexprnoexcept |
Definition at line 526 of file direct_map.h.
|
inlinestaticconstexprnoexcept |
Definition at line 560 of file direct_map.h.
|
inlinestaticconstexprnoexcept |
Definition at line 387 of file direct_map.h.
|
inlinestaticconstexprnoexcept |
Definition at line 557 of file direct_map.h.
|
inlineconstexpr |
Definition at line 268 of file direct_map.h.
|
constexprdefaultnoexcept |
|
inlineconstexpr |
Definition at line 285 of file direct_map.h.
|
inlineconstexprnoexcept |
Definition at line 323 of file direct_map.h.
|
inlineconstexprnoexcept |
Definition at line 356 of file direct_map.h.
|
inlineconstexprnoexcept |
Definition at line 359 of file direct_map.h.
|
inlineconstexprnoexcept |
Definition at line 366 of file direct_map.h.
|
inlineconstexprnoexcept |
Definition at line 369 of file direct_map.h.
|
inlineconstexprnoexcept |
Definition at line 380 of file direct_map.h.
|
inlineconstexprnoexcept |
Definition at line 383 of file direct_map.h.
|
inlineconstexprnoexcept |
Definition at line 487 of file direct_map.h.
|
inlinestaticconstexprnoexcept |
Definition at line 624 of file direct_map.h.
|
inlineconstexpr |
Definition at line 442 of file direct_map.h.
|
inlinestaticconstexprnoexcept |
Definition at line 620 of file direct_map.h.
|
inlineconstexprnoexcept |
Definition at line 535 of file direct_map.h.
|
inlineconstexprnoexcept |
Definition at line 545 of file direct_map.h.
|
friend |
Definition at line 583 of file direct_map.h.
|
friend |
Definition at line 590 of file direct_map.h.
|
friend |
Definition at line 603 of file direct_map.h.
|
friend |
Definition at line 564 of file direct_map.h.
|
friend |
Definition at line 597 of file direct_map.h.
|
friend |
Definition at line 609 of file direct_map.h.