Lumiera 0.pre.04
»edit your freedom«
Loading...
Searching...
No Matches
WithIdxSeq< N > Class Template Reference

#include "lib/meta/variadic-helper.hpp"

Description

template<size_t N>
class lib::meta::WithIdxSeq< N >

helper to invoke a functor, passing instances of std::integral_constant

Template Parameters
Nsize of the index-sequence to use for instantiation
Remarks
the functor is given for...
  • to be invoked either (as void) for each index
  • or as a predicate, combining the results with AND / OR

Definition at line 221 of file variadic-helper.hpp.

Static Public Member Functions

template<class FUN >
static constexpr void invoke (FUN &&fun)
 
template<class FUN >
static constexpr bool andAll (FUN &&fun)
 
template<class FUN >
static constexpr bool orAny (FUN &&fun)
 

Private Types

using IdxSeq = std::make_index_sequence< N >
 

Static Private Member Functions

template<class FUN , size_t... idx>
static constexpr void invoke_forEach (FUN &&fun, std::index_sequence< idx... >)
 
template<class FUN , size_t... idx>
static constexpr bool and_forEach (FUN &&fun, std::index_sequence< idx... >)
 
template<class FUN , size_t... idx>
static constexpr bool or_forEach (FUN &&fun, std::index_sequence< idx... >)
 

Member Typedef Documentation

◆ IdxSeq

template<size_t N>
using IdxSeq = std::make_index_sequence<N>
private

Definition at line 244 of file variadic-helper.hpp.

Member Function Documentation

◆ invoke_forEach()

template<size_t N>
template<class FUN , size_t... idx>
static constexpr void invoke_forEach ( FUN &&  fun,
std::index_sequence< idx... >   
)
inlinestaticconstexprprivate

Definition at line 225 of file variadic-helper.hpp.

Referenced by WithIdxSeq< N >::invoke().

+ Here is the caller graph for this function:

◆ and_forEach()

template<size_t N>
template<class FUN , size_t... idx>
static constexpr bool and_forEach ( FUN &&  fun,
std::index_sequence< idx... >   
)
inlinestaticconstexprprivate

Definition at line 232 of file variadic-helper.hpp.

Referenced by WithIdxSeq< N >::andAll().

+ Here is the caller graph for this function:

◆ or_forEach()

template<size_t N>
template<class FUN , size_t... idx>
static constexpr bool or_forEach ( FUN &&  fun,
std::index_sequence< idx... >   
)
inlinestaticconstexprprivate

Definition at line 239 of file variadic-helper.hpp.

Referenced by WithIdxSeq< N >::orAny().

+ Here is the caller graph for this function:

◆ invoke()

template<size_t N>
template<class FUN >
static constexpr void invoke ( FUN &&  fun)
inlinestaticconstexpr

Definition at line 249 of file variadic-helper.hpp.

References WithIdxSeq< N >::invoke_forEach().

+ Here is the call graph for this function:

◆ andAll()

template<size_t N>
template<class FUN >
static constexpr bool andAll ( FUN &&  fun)
inlinestaticconstexpr

Definition at line 256 of file variadic-helper.hpp.

References WithIdxSeq< N >::and_forEach().

+ Here is the call graph for this function:

◆ orAny()

template<size_t N>
template<class FUN >
static constexpr bool orAny ( FUN &&  fun)
inlinestaticconstexpr

Definition at line 263 of file variadic-helper.hpp.

References WithIdxSeq< N >::or_forEach().

+ Here is the call graph for this function:
+ Collaboration diagram for WithIdxSeq< N >:

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