58 template<
typename TA,
int item>
77 template<
typename TA,
int from,
int end>
85 static bool contains(
const Type& item);
97 typedef typename S::Type Type;
99 static bool contains(
const Type& item)
101 return !S::contains(item);
108 template<
class TI1,
class TI2,
typename TA=
typename TI1::Type>
112 static bool contains(
const TA& item);
115 template<
typename TA>
122 template<
typename TA>
129 template<
typename TA,
int i>
135 template<
typename TA,
int i>
141 template<
typename TA,
int from,
int to>
142 inline bool EnumRange<TA,from,to>::contains(
const Type& item)
144 return from<=item && item<=to;
147 template<
typename TA,
int from,
int to>
148 inline std::ostream&
operator<<(std::ostream& os,
const EnumRange<TA,from,to>&)
150 return os<<
"["<<from<<
" - "<<to<<
"]";
153 template<
class TI1,
class TI2,
typename TA>
154 inline bool Combine<TI1,TI2,TA>::contains(
const TA& item)
156 return TI1::contains(item) ||
160 template<
class TI1,
class TI2>
161 inline Combine<TI1,TI2,typename TI1::Type> combine(
const TI1& set1,
const TI2& set2)
163 return Combine<TI1,TI2,typename TI1::Type>();
166 template<
class TI1,
class TI2,
class T>
167 inline std::ostream&
operator<<(std::ostream& os,
const Combine<TI1,TI2,T>&)
169 return os << TI1()<<
" "<<TI2();
A set containing everything.
Definition: enumset.hh:43
TA Type
The POD type the set holds.
Definition: enumset.hh:48
A set combining two other sets.
Definition: enumset.hh:110
An empty set.
Definition: enumset.hh:26
TA Type
The POD type the set holds.
Definition: enumset.hh:31
A set consisting only of one item.
Definition: enumset.hh:60
TA Type
The type the set holds.
Definition: enumset.hh:65
A set representing a range including the borders.
Definition: enumset.hh:79
TA Type
The type the set holds.
Definition: enumset.hh:84
The negation of a set. An item is contained in the set if and only if it is not contained in the nega...
Definition: enumset.hh:95
static bool contains(const Type &attribute)
Always returns false.
Definition: enumset.hh:123
std::ostream & operator<<(std::ostream &s, const array< T, N > &e)
Output operator for array.
Definition: array.hh:159
static bool contains(const Type &attribute)
Always returns false.
Definition: enumset.hh:116
static bool contains(const Type &attribute)
Tests whether an item is in the set.
Definition: enumset.hh:130
Dune namespace.
Definition: alignment.hh:14
Definition of the DUNE_UNUSED macro for the case that config.h is not available.
#define DUNE_UNUSED_PARAMETER(parm)
A macro to mark intentional unused function parameters with.
Definition: unused.hh:18