1#ifndef DUNE_FEM_CAPABILITIES_HH
2#define DUNE_FEM_CAPABILITIES_HH
8#include <dune/fem/misc/griddeclaration.hh>
9#include <dune/fem/misc/metaprogramming.hh>
17 namespace Capabilities
23 template<
class Gr
id >
24 struct hasHierarchicIndexSet;
26 template<
class Gr
id >
27 struct hasHierarchicIndexSet< const Grid >
29 static const bool v =
false;
32 template<
class Gr
id >
33 struct hasHierarchicIndexSet
35 static const bool v =
false;
39 template<
int dim,
int dimw, ALUGr
idElementType elType, ALUGr
idRefinementType refineType,
class Comm >
40 struct hasHierarchicIndexSet< ALUGrid< dim, dimw, elType, refineType, Comm > >
42 static const bool v =
true;
46#if HAVE_DUNE_P4ESTGRID
47 template<
int dim,
int dimworld,
class ctype >
48 struct hasHierarchicIndexSet< P4estGrid< dim, dimworld, ctype > >
50 static const bool v =
true;
55 struct hasHierarchicIndexSet< OneDGrid >
57 static const bool v =
false;
61 struct hasHierarchicIndexSet< UGGrid< dim > >
63 static const bool v =
false;
66 template<
int dim,
class CoordCont >
67 struct hasHierarchicIndexSet< YaspGrid< dim, CoordCont > >
69 static const bool v =
false;
73 template<
class HostGr
id,
class CoordFunction,
class Allocator >
74 struct hasHierarchicIndexSet< GeometryGrid< HostGrid, CoordFunction, Allocator > >
77 static const bool v = false ;
89 namespace Capabilities
95 template<
class Gr
id >
96 class hasAllCodimEntities
98 template<
unsigned int codim >
104 static const bool v = Loop< MetaAnd, Codim, Grid :: dimension > :: v;
105 static const bool value = v;
112 template<
class Gr
id >
113 struct supportsCallbackAdaptation
115 static const bool v =
false;
118 template<
class Gr
id >
119 struct supportsCallbackAdaptation< const Grid >
121 static const bool v = Dune::Fem::Capabilities::supportsCallbackAdaptation< Grid > :: v;
125 template<
int dim,
int dimworld, ALUGr
idElementType elType, ALUGr
idRefinementType refineType,
class Comm >
126 struct supportsCallbackAdaptation< ALUGrid< dim, dimworld, elType, refineType, Comm > >
128 static const bool v =
true;
132#if HAVE_DUNE_P4ESTGRID
133 template<
int dim,
int dimworld,
class ctype >
134 struct supportsCallbackAdaptation< P4estGrid< dim, dimworld, ctype > >
136 static const bool v =
true;
140 template<
int dim,
int dimworld >
141 struct supportsCallbackAdaptation< AlbertaGrid< dim, dimworld > >
143 static const bool v =
true;
146 template<
class HostGr
id,
class CoordFunction,
class Allocator >
147 struct supportsCallbackAdaptation< GeometryGrid< HostGrid, CoordFunction, Allocator > >
149 static const bool v = supportsCallbackAdaptation< HostGrid > :: v;
152#if HAVE_DUNE_METAGRID
153 template<
class HostGr
id >
154 struct supportsCallbackAdaptation< CartesianGrid< HostGrid > >
156 static const bool v = supportsCallbackAdaptation< HostGrid > :: v;
165 template<
class Gr
id >
166 struct isLocallyAdaptive
168 static const bool v =
false;
171 template<
class Gr
id >
172 struct isLocallyAdaptive< const Grid >
174 static const bool v = Dune::Fem::Capabilities::isLocallyAdaptive< Grid > :: v;
178 template<
int dim,
int dimworld, ALUGr
idElementType elType, ALUGr
idRefinementType refineType,
class Comm >
179 struct isLocallyAdaptive< ALUGrid< dim, dimworld, elType, refineType, Comm > >
181 static const bool v =
true;
185#if HAVE_DUNE_P4ESTGRID
186 template<
int dim,
int dimworld,
class ctype >
187 struct isLocallyAdaptive< P4estGrid< dim, dimworld, ctype > >
189 static const bool v =
true;
193 template<
int dim,
int dimworld >
194 struct isLocallyAdaptive< AlbertaGrid< dim, dimworld > >
196 static const bool v =
true;
200 struct isLocallyAdaptive< UGGrid< dim > >
202 static const bool v =
true;
206 struct isLocallyAdaptive< OneDGrid >
208 static const bool v =
true;
211 template<
class HostGr
id,
class CoordFunction,
class Allocator >
212 struct isLocallyAdaptive< GeometryGrid< HostGrid, CoordFunction, Allocator > >
214 static const bool v = isLocallyAdaptive< HostGrid > :: v;
217#if HAVE_DUNE_METAGRID
218 template<
class HostGr
id >
219 struct isLocallyAdaptive< CartesianGrid< HostGrid > >
221 static const bool v = isLocallyAdaptive< HostGrid > :: v;
230 template<
class Gr
id >
233 static const bool v =
false;
Various macros to work with Dune module version numbers.
A set of traits classes to store static information about grid implementation.
Dune namespace.
Definition: alignedallocator.hh:13
Specialize with 'true' for all codims that a grid implements entities for. (default=false)
Definition: capabilities.hh:58