repr 0.1
Reconstructable string representations and more
Loading...
Searching...
No Matches
librepr::ctei::RangeList< Ranges > Struct Template Reference

#include <range_list.h>

Inheritance diagram for librepr::ctei::RangeList< Ranges >:
[legend]
Collaboration diagram for librepr::ctei::RangeList< Ranges >:
[legend]

Public Types

using last = typename RangeList::template get< 0 >
 
template<auto Idx>
using add = std::conditional_t< next_index==Idx, typename RangeList::template tail< 0 >::template prepend< typename last::template expand< 1 > >, typename RangeList::template prepend< Range< Idx > > >
 
template<typename T >
using add_range = std::conditional_t< next_index==T::min, typename RangeList::template tail< 0 >::template prepend< typename last::template expand< T::size > >, typename RangeList::template prepend< T > >
 
template<typename T , auto V, auto Idx = V>
using try_one = std::conditional_t< is_enum_value< T, V >(), add< Idx >, RangeList >
 
using map = RangeList< F< Ts >... >
 
using map_t = RangeList< typename F< Ts >::type... >
 
using get = typename pack::Split< Idx, RangeList< Ts... > >::type
 
using split = RangeList< typename do_split< Idx >::head, typename do_split< Idx >::tail >
 
using head = typename do_split< Idx >::head
 
using tail = typename do_split< Idx >::tail
 
using append = RangeList< Ts..., T >
 
using prepend = RangeList< T, Ts... >
 
using to = T< Ts... >
 

Static Public Member Functions

static constexpr bool is_binary_powers ()
 
static constexpr decltype(auto) invoke (F &&callable, Args &&... args)
 
static constexpr void for_each (F &&callable, Args &&... args)
 
static constexpr void enumerate (F &&callable, Args &&... args)
 

Static Public Attributes

static constexpr auto next_index = last::max + 1
 
static constexpr std::size_t size
 

Member Typedef Documentation

◆ add

template<typename... Ranges>
template<auto Idx>
using librepr::ctei::RangeList< Ranges >::add = std::conditional_t< next_index == Idx, typename RangeList::template tail<0>::template prepend<typename last::template expand<1> >, typename RangeList::template prepend<Range<Idx> > >

◆ add_range

template<typename... Ranges>
template<typename T >
using librepr::ctei::RangeList< Ranges >::add_range = std::conditional_t< next_index == T::min, typename RangeList::template tail<0>::template prepend<typename last::template expand<T::size> >, typename RangeList::template prepend<T> >

◆ append

using librepr::TypeListBase< RangeList , Ts >::append = RangeList <Ts..., T>
inherited

◆ get

using librepr::TypeListBase< RangeList , Ts >::get = typename pack::Split<Idx, RangeList <Ts...> >::type
inherited

◆ head

using librepr::TypeListBase< RangeList , Ts >::head = typename do_split<Idx>::head
inherited

◆ last

template<typename... Ranges>
using librepr::ctei::RangeList< Ranges >::last = typename RangeList::template get<0>

◆ map

using librepr::TypeListBase< RangeList , Ts >::map = RangeList <F<Ts>...>
inherited

◆ map_t

using librepr::TypeListBase< RangeList , Ts >::map_t = RangeList <typename F<Ts>::type...>
inherited

◆ prepend

using librepr::TypeListBase< RangeList , Ts >::prepend = RangeList <T, Ts...>
inherited

◆ split

◆ tail

using librepr::TypeListBase< RangeList , Ts >::tail = typename do_split<Idx>::tail
inherited

◆ to

using librepr::TypeListBase< RangeList , Ts >::to = T<Ts...>
inherited

◆ try_one

template<typename... Ranges>
template<typename T , auto V, auto Idx = V>
using librepr::ctei::RangeList< Ranges >::try_one = std::conditional_t<is_enum_value<T, V>(), add<Idx>, RangeList>

Member Function Documentation

◆ enumerate()

static constexpr void librepr::TypeListBase< RangeList , Ts >::enumerate ( F &&  callable,
Args &&...  args 
)
inlinestaticconstexprinherited

◆ for_each()

static constexpr void librepr::TypeListBase< RangeList , Ts >::for_each ( F &&  callable,
Args &&...  args 
)
inlinestaticconstexprinherited

◆ invoke()

static constexpr decltype(auto) librepr::TypeListBase< RangeList , Ts >::invoke ( F &&  callable,
Args &&...  args 
)
inlinestaticconstexprinherited

◆ is_binary_powers()

template<typename... Ranges>
static constexpr bool librepr::ctei::RangeList< Ranges >::is_binary_powers ( )
inlinestaticconstexpr

Member Data Documentation

◆ next_index

template<typename... Ranges>
constexpr auto librepr::ctei::RangeList< Ranges >::next_index = last::max + 1
staticconstexpr

◆ size

constexpr std::size_t librepr::TypeListBase< RangeList , Ts >::size
staticconstexprinherited

The documentation for this struct was generated from the following file: