#include <nk/value/value.hpp>#include <cstddef>#include <memory_resource>Go to the source code of this file.
Functions | |
| void | nk::runtime::registerContainersRuntime (Engine &engine) |
| Registers containers.Map and dictionary builtins in the engine. | |
| Value | nk::runtime::containers::map (std::pmr::memory_resource *mr=nullptr) |
| Creates an empty containers.Map (handle semantics: copies alias shared state). | |
| Value | nk::runtime::containers::dictionary (std::pmr::memory_resource *mr=nullptr) |
| Creates an empty dictionary (value semantics: copies are independent). | |
| void | nk::runtime::containers::set (Value &m, const Value &key, const Value &val) |
| Inserts or updates key-value pair in container in place. | |
| Value | nk::runtime::containers::get (const Value &m, const Value &key) |
| Looks up value associated with specified key (throws if key absent). | |
| bool | nk::runtime::containers::isKey (const Value &m, const Value &key) |
| Checks whether specified key exists in container. | |
| void | nk::runtime::containers::remove (Value &m, const Value &key) |
| Removes specified key and its associated value from container. | |
| std::size_t | nk::runtime::containers::count (const Value &m) |
| Returns the number of key-value pairs in container. | |
| Value | nk::runtime::containers::keys (const Value &m, std::pmr::memory_resource *mr=nullptr) |
| Extracts all keys from container as a column array. | |
| Value | nk::runtime::containers::values (const Value &m, std::pmr::memory_resource *mr=nullptr) |
| Extracts all values from container as an array or cell array. | |