Class modeling an immutable map of configuration entries.
More...
#include <config.hh>
|
|
using | key_type = std::string_view |
| | The key type.
|
| |
|
using | mapped_type = ConstConfig |
| | The mapped type.
|
| |
|
using | value_type = std::pair< key_type, mapped_type > |
| | The value type.
|
| |
|
using | size_type = std::size_t |
| | The size type.
|
| |
|
using | difference_type = std::ptrdiff_t |
| | The difference type.
|
| |
|
using | reference = value_type |
| | The reference type.
|
| |
|
using | pointer = Detail::ArrowProxy< value_type > |
| | The pointer type.
|
| |
|
using | iterator = Detail::RandomAccessIterator< ConstConfigMap > |
| | The iterator type.
|
| |
|
| | ConstConfigMap (clingo_config_t const *stats, ProgramId key) |
| | Construct from the underlying C API type and a key.
|
| |
| auto | size () const -> size_t |
| | Get the size of the map.
|
| |
| auto | at (size_t index) const -> value_type |
| | Get the name configuration entry pair at the given index in the map.
|
| |
| auto | get (std::string_view name) const -> ConstConfig |
| | Get the configuration entry with the given name in the map.
|
| |
| auto | operator[] (std::string_view name) const -> ConstConfig |
| | Get the configuration entry with the given name in the map.
|
| |
| auto | contains (std::string_view name) const -> bool |
| | Check if the map contains a configuration entry with the given name.
|
| |
| auto | begin () const -> iterator |
| | Get an iterator to the beginning of the map.
|
| |
| auto | end () const -> iterator |
| | Get an iterator to the end of the map.
|
| |
Class modeling an immutable map of configuration entries.
◆ ConstConfigMap()
Construct from the underlying C API type and a key.
- Parameters
-
| stats | the underlying C API type |
| key | the key of the configuration entry |
◆ at()
| auto Clingo::ConstConfigMap::at |
( |
size_t |
index | ) |
const -> value_type |
|
inline |
Get the name configuration entry pair at the given index in the map.
- Parameters
-
| index | the index of the configuration entry |
- Returns
- the name configuration entry pair at the given index
◆ begin()
| auto Clingo::ConstConfigMap::begin |
( |
| ) |
const -> iterator |
|
inline |
Get an iterator to the beginning of the map.
- Returns
- an iterator to the beginning of the map
◆ contains()
| auto Clingo::ConstConfigMap::contains |
( |
std::string_view |
name | ) |
const -> bool |
|
inline |
Check if the map contains a configuration entry with the given name.
- Parameters
-
| name | the name of the configuration entry |
- Returns
- true if the map contains an entry with the given name, false otherwise
◆ end()
| auto Clingo::ConstConfigMap::end |
( |
| ) |
const -> iterator |
|
inline |
Get an iterator to the end of the map.
- Returns
- an iterator to the end of the map
◆ get()
| auto Clingo::ConstConfigMap::get |
( |
std::string_view |
name | ) |
const -> ConstConfig |
|
inline |
Get the configuration entry with the given name in the map.
- Parameters
-
| name | the name of the configuration entry |
- Returns
- the configuration entry with the given name
◆ operator[]()
| auto Clingo::ConstConfigMap::operator[] |
( |
std::string_view |
name | ) |
const -> ConstConfig |
|
inline |
Get the configuration entry with the given name in the map.
- Parameters
-
| name | the name of the configuration entry |
- Returns
- the configuration entry with the given name
◆ size()
| auto Clingo::ConstConfigMap::size |
( |
| ) |
const -> size_t |
|
inline |
Get the size of the map.
- Returns
- the size of the map
The documentation for this class was generated from the following file: