![]() |
Dune-Functions 2.11
|
Loading...
Searching...
No Matches
utility.hh
Go to the documentation of this file.
25auto forwardAsStaticInteger(std::integer_sequence<size_type, firstValue> values, const size_type& i, F&& f, Args&&... args)
31template<class F, class size_type, size_type firstValue, size_type secondValue, size_type... otherValues, class... Args>
33auto forwardAsStaticInteger(std::integer_sequence<size_type, firstValue, secondValue, otherValues...> values, const size_type i, F&& f, Args&&... args)
38 return forwardAsStaticInteger(std::integer_sequence<size_type, secondValue, otherValues...>(), i, std::forward<F>(f), std::forward<Args>(args)...);
71 return forwardAsStaticInteger(std::make_index_sequence<end>{}, i, std::forward<F>(f), std::forward<Args>(args)...);
153 auto transformTupleHelper(F&& f, const std::tuple<T1...>& tuple1, const std::tuple<T2...>& tuple2, std::index_sequence<k...>)
174 -> decltype(Imp::transformTupleHelper(std::forward<F>(f), tuple, std::index_sequence_for<T...>{}))
194 -> decltype(Imp::transformTupleHelper(std::forward<F>(f), tuple1, tuple2, std::index_sequence_for<T1...>{}))
196 return Imp::transformTupleHelper(std::forward<F>(f), tuple1, tuple2, std::index_sequence_for<T1...>{});
244 using type = typename std::tuple<typename LastType<T...>::type, std::tuple_element_t<I,std::tuple<T...>>...>;
260 using type = typename Imp::RotateHelper<std::tuple<T...>, std::make_index_sequence<sizeof...(T)-1>>::type;
BCRSMatrix< FieldMatrix< T, n, m >, A >::size_type size_type
typename Imp::ExpandTupleHelper< T, ArgTuple >::Type ExpandTuple
Expand tuple arguments as template arguments.
Definition utility.hh:102
typename Imp::TransformTupleHelper< F, Tuples... >::Type TransformTuple
Transform tuple types argument using type-functor.
Definition utility.hh:139
static constexpr auto isCallable()
Check if f is callable with given argument list.
Definition functionconcepts.hh:51
auto transformTuple(F &&f, const std::tuple< T... > &tuple) -> decltype(Imp::transformTupleHelper(std::forward< F >(f), tuple, std::index_sequence_for< T... >{}))
Transform tuple value using a functor.
Definition utility.hh:173
auto callableCheck(Expression f)
Create a predicate for checking validity of expressions.
Definition utility.hh:287
auto forwardAsStaticIndex(const size_type &i, F &&f, Args &&... args) -> decltype(f(Dune::Indices::_0, std::forward< Args >(args)...))
Transform dynamic index to static index_constant.
Definition utility.hh:68
auto negatePredicate(Check check)
Negate given predicate.
Definition utility.hh:312
STL namespace.
auto forwardCapture(T &&t)
Create a capture object for perfect forwarding.
Definition utility.hh:380
auto forwardAsStaticInteger(std::integer_sequence< size_type, firstValue > values, const size_type &i, F &&f, Args &&... args) -> decltype(f(std::integral_constant< size_type, firstValue >(), std::forward< Args >(args)...))
Definition utility.hh:25
typename Imp::IntegerSequenceTupleHelper< IntegerSequence >::Type IntegerSequenceTuple
Transform integer_sequence<I,k...> to tuple<integral_constant<I,k>...>
Definition utility.hh:219
constexpr index_constant< 0 > _0
iterator end()
auto overload(F &&... f)
std::tuple_element_t< sizeof...(T) -1, std::tuple< T... > > type
Definition utility.hh:231
Rotate type list by one, such that last entry is moved to first position.
Definition utility.hh:259
typename Imp::RotateHelper< std::tuple< T... >, std::make_index_sequence< sizeof...(T) -1 > >::type type
Definition utility.hh:260
T forward(T... args)
T make_tuple(T... args)
