|
KUMI v5.0.0
Gorgeous Garnet
|
Utilities to manipulate functions and types in a functional way. More...
Classes | |
| struct | kumi::function::adjacent_unicity_t |
| Logic provider to compute the index map associated to the adjacent unicity operation. More... | |
| class | kumi::function::boolean_and |
| logical and monoid whose identity element is true. More... | |
| class | kumi::function::boolean_or |
| logical or monoid whose identity element is false. More... | |
| class | kumi::function::boolean_xor |
| logical xor monoid whose identity element is false. More... | |
| class | kumi::function::foldable< T > |
| Functional wrapper for values to facilitate pipelined transformations. More... | |
| class | kumi::function::numeric_add |
| Addition monoid whose identity element is 0. More... | |
| class | kumi::function::numeric_prod |
| Multiplication monoid whose identity element is 1. More... | |
| class | kumi::function::scannable< F, V > |
| Functional wrapper that accumulates state during a transformation chain. More... | |
| struct | kumi::function::select_t |
| Logic provider to compute the index map associated to the partition operation. More... | |
| struct | kumi::function::unique_t |
| Logic provider to compute the index map associated to the all_unique operation. More... | |
Typedefs | |
| template<std::size_t I, typename T, typename U> | |
| using | kumi::function::element_or_t = std::remove_cvref_t<decltype(kumi::function::get_or<I>(std::declval<T>(), std::declval<U>()))> |
| Computes the Ith element type of a kumi::product_type, or a fallback type U otherwise. | |
Functions | |
| template<typename C, typename... Ts> requires (std::is_move_constructible_v<std::decay_t<C>> && (std::is_move_constructible_v<std::decay_t<Ts>> && ...)) | |
| constexpr auto | kumi::bind_back (C &&c, Ts &&... ts) noexcept(std::is_nothrow_move_constructible_v< std::decay_t< C > > &&(std::is_nothrow_move_constructible_v< std::decay_t< Ts > > &&...)) |
| Returns a callable object with ts bound as its trailing arguments, reducing c arity. | |
| template<typename C, typename... Ts> requires (std::is_move_constructible_v<std::decay_t<C>> && (std::is_move_constructible_v<std::decay_t<Ts>> && ...)) | |
| constexpr auto | kumi::bind_front (C &&c, Ts &&... ts) noexcept(std::is_nothrow_move_constructible_v< std::decay_t< C > > &&(std::is_nothrow_move_constructible_v< std::decay_t< Ts > > &&...)) |
| Returns a callable object with ts bound as its leading arguments, reducing c arity. | |
| template<std::size_t I, typename T, typename V> | |
| constexpr decltype(auto) | kumi::function::get_or (T &&t, V &&v) |
| Returns the Ith element of t if t is a kumi::product_type, an instance of v otherwise. | |
| template<typename C, typename... Ts> | |
| constexpr decltype(auto) | kumi::invoke (C &&c, Ts &&... ts) |
| Invoke the Callable object c with a pack of arguments. | |
| template<typename R, typename C, typename... Ts> requires (std::is_invocable_r_v<R, C, Ts...>) | |
| constexpr R | kumi::invoke_r (C &&c, Ts &&... ts) noexcept(std::is_nothrow_invocable_r_v< R, C, Ts... >) |
| Invoke the Callable object c with a pack of arguments with return type R. | |
Variables | |
| constexpr kumi::function::boolean_and | kumi::function::bit_and {} |
| Callable object matching the kumi::boolean_and monoid, usable with kumi::algorithm. | |
| constexpr kumi::function::boolean_or | kumi::function::bit_or {} |
| Callable object matching the kumi::boolean_or monoid, usable with kumi::algorithm. | |
| constexpr kumi::function::boolean_xor | kumi::function::bit_xor {} |
| Callable object matching the kumi::boolean_xor monoid, usable with kumi::algorithm. | |
| struct kumi::function::cartesian_product_t | kumi::function::cartesian_producer |
| Callable object computing the index map associated to the cartesian product operation. | |
| struct kumi::function::cat_t | kumi::function::concatenater |
| Callable object computing the index map associated to the concatenation operation. | |
| struct kumi::function::extract_t | kumi::function::extractor |
| Callable object computing the index map associated to the extraction operation. | |
| constexpr kumi::function::numeric_prod | kumi::function::multiplies {} |
| Callable object matching the kumi::numeric_prod monoid, usable with kumi::algorithm. | |
| constexpr kumi::function::numeric_add | kumi::function::plus {} |
| Callable object matching the kumi::numeric_add monoid, usable with kumi::algorithm. | |
| struct kumi::function::reduce_t | kumi::function::reducer |
| Callable object computing the index map associated to the reduction operation. | |
| struct kumi::function::repeat_t | kumi::function::repeater |
| Callable object generating an index sequence repeating a constant index. | |
| struct kumi::function::reverse_t | kumi::function::reverser |
| Callable object computing the reversed index sequence. | |
| struct kumi::function::rotate_t | kumi::function::rotater |
| Callable object computing the index map associated to the rotation operation. | |
| constexpr kumi::function::select_t | kumi::function::selector {} |
| Callable object computing the index map associated to the selection operation. | |
| struct kumi::function::shift_t | kumi::function::shifter |
| Callable object computing linear indexing translations. | |
| template<typename T, auto V> | |
| constexpr auto | kumi::function::size_or_v = V |
| If T is a kumi::product_type, returns its number of elements otherwise returns V;. | |
| struct kumi::function::slice_t | kumi::function::slicer |
| Callable object computing the index map associated to a slicing (begin, end, step) operation. | |
| struct kumi::function::split_t | kumi::function::splitter |
| Callable object computing underlying index sequences of the input domain divided in two parts. | |
| struct kumi::function::tile_t | kumi::function::tiler |
| Callable object computing multi-dimensional window block layout configurations. | |
| constexpr kumi::function::adjacent_unicity_t | kumi::function::uniqued {} |
| Callable object computing the index map associated to the adjacent unicity operation. | |
| constexpr kumi::function::unique_t | kumi::function::uniquer {} |
| Callable object computing the index map associated to the deduplication operation. | |
| struct kumi::function::zip_t | kumi::function::zipper |
| Callable object creating the index sequence corresponding to the zip operation. | |