00001
00002
00003
00004 #ifndef DUNE_COMMON_INDICES_HH
00005 #define DUNE_COMMON_INDICES_HH
00006
00007 #include <cstddef>
00008 #include <type_traits>
00009
00010
00011 namespace Dune
00012 {
00025 template<std::size_t i>
00026 using index_constant = std::integral_constant<std::size_t, i>;
00027
00028
00029
00046 namespace Indices
00047 {
00049 constexpr index_constant< 0> _0 = {};
00050
00052 constexpr index_constant< 1> _1 = {};
00053
00055 constexpr index_constant< 2> _2 = {};
00056
00058 constexpr index_constant< 3> _3 = {};
00059
00061 constexpr index_constant< 4> _4 = {};
00062
00064 constexpr index_constant< 5> _5 = {};
00065
00067 constexpr index_constant< 6> _6 = {};
00068
00070 constexpr index_constant< 7> _7 = {};
00071
00073 constexpr index_constant< 8> _8 = {};
00074
00076 constexpr index_constant< 9> _9 = {};
00077
00079 constexpr index_constant<10> _10 = {};
00080
00082 constexpr index_constant<11> _11 = {};
00083
00085 constexpr index_constant<12> _12 = {};
00086
00088 constexpr index_constant<13> _13 = {};
00089
00091 constexpr index_constant<14> _14 = {};
00092
00094 constexpr index_constant<15> _15 = {};
00095
00097 constexpr index_constant<16> _16 = {};
00098
00100 constexpr index_constant<17> _17 = {};
00101
00103 constexpr index_constant<18> _18 = {};
00104
00106 constexpr index_constant<19> _19 = {};
00107
00108 }
00109
00110 }
00111
00112 #endif // DUNE_COMMON_INDICES_HH