|
| | Map2d ()=default |
| | Initialises a new instance of the Map2d class.
|
| |
| | Map2d (TMap< TRow, TMap< TCol, TCell > > &&data) noexcept |
| | Initialises a new instance of the Map2d class from a standard C++ 2D mapping.
|
| |
| IteratorType | begin () noexcept |
| | Gets an iterator to the beginning of the map.
|
| |
| IteratorType | end () noexcept |
| | Gets an iterator to the element following the element of the map.
|
| |
| ConstIteratorType | begin () const noexcept |
| | Gets an read-only iterator to the beginning of the map.
|
| |
| ConstIteratorType | end () const noexcept |
| | Gets an read-only iterator to the element following the element of the map.
|
| |
| ConstIteratorType | cbegin () const noexcept |
| | Gets an read-only iterator to the beginning of the map.
|
| |
| ConstIteratorType | cend () const noexcept |
| | Gets an read-only iterator to the element following the element of the map.
|
| |
| bool | empty () const noexcept |
| | Determine whether the container is empty.
|
| |
| bool | empty (const TRow &row_key) const |
| | Determine whether a given row container is empty.
|
| |
| std::size_t | rows () const noexcept |
| | Gets the number of rows.
|
| |
| std::size_t | columns (const TRow &row_key) const |
| | Gets the number of columns at a given row.
|
| |
| bool | contains (const TRow &row_key) const noexcept |
| | Determines whether the map contains a row.
|
| |
| bool | contains (const TRow &row_key, const TCol &col_key) const |
| | Determines whether the map contains a value.
|
| |
| TMap< TCol, TCell > & | at (const TRow &row_key) |
| | Gets a row dataset with bounds checking.
|
| |
| const TMap< TCol, TCell > & | at (const TRow &row_key) const |
| | Gets a read-only row dataset with bounds checking.
|
| |
| TCell & | at (const TRow &row_key, const TCol &col_key) |
| | Gets a value at a cell by row and column with bounds checking.
|
| |
| const TCell & | at (const TRow &row_key, const TCol &col_key) const |
| | Gets a read-only value at a cell by row and column with bounds checking.
|
| |
| template<class... FArgs> |
| auto | insert_row (FArgs &&...args) noexcept |
| | Insert a row into the table.
|
| |
| template<class FRow , class... FArgs> |
| auto | insert (FRow &&row_key, FArgs &&...args) noexcept |
| | Insert a column into a given row of the table.
|
| |
| template<class... FArgs> |
| auto | emplace_row (FArgs &&...args) noexcept |
| | Emplace a row into the table.
|
| |
| template<class FRow , class... FArgs> |
| auto | emplace (FRow &&row_key, FArgs &&...args) noexcept |
| | Emplace a column into a given row of the table.
|
| |
template<template< class... > class TMap, class TRow, class TCol, class TCell>
class hgps::Map2d< TMap, TRow, TCol, TCell >
Defines the two-dimensional map (lookup table) data type.
- Template Parameters
-
| TMap | underlying standard map type |
| TRow | Rows date type |
| TCol | Columns data type |
| TCell | Cell value data type |
template<template< class... > class TMap, class TRow , class TCol , class TCell >
template<class FRow , class... FArgs>
| auto hgps::Map2d< TMap, TRow, TCol, TCell >::emplace |
( |
FRow && |
row_key, |
|
|
FArgs &&... |
args |
|
) |
| |
|
inlinenoexcept |
Emplace a column into a given row of the table.
- Parameters
-
| row_key | The row identifier |
| ...args | The arguments to forward to the row emplace method |
- Returns
- Return type for the underlying map's emplace method
template<template< class... > class TMap, class TRow , class TCol , class TCell >
template<class FRow , class... FArgs>
| auto hgps::Map2d< TMap, TRow, TCol, TCell >::insert |
( |
FRow && |
row_key, |
|
|
FArgs &&... |
args |
|
) |
| |
|
inlinenoexcept |
Insert a column into a given row of the table.
- Parameters
-
| row_key | The row identifier |
| ...args | The arguments to forward to the column insert method |
- Returns
- Return type for the underlying map's insert method