dune-spgrid 2.8.0
Loading...
Searching...
No Matches
capabilities.hh
Go to the documentation of this file.
1#ifndef DUNE_SPGRID_CAPABILITIES_HH
2#define DUNE_SPGRID_CAPABILITIES_HH
3
4#if HAVE_MPI
5#include <mpi.h>
6#endif
7
8#include <dune/geometry/type.hh>
9
10#include <dune/grid/common/capabilities.hh>
11
13
15
21namespace Dune
22{
23
24 // Capabilities
25 // ------------
26
28 namespace Capabilities
29 {
30
35 template< class ct, int dim, template< int > class Ref, class Comm >
36 struct hasSingleGeometryType< SPGrid< ct, dim, Ref, Comm > >
37 {
40 static const bool v = true;
42 static const unsigned int topologyId = GeometryTypes::cube(dim).id();
43 };
44
58 template< class ct, int dim, template< int > class Ref, class Comm >
59 struct isCartesian< SPGrid< ct, dim, Ref, Comm > >
60 {
62 static const bool v = true;
63 };
64
70 template< class ct, int dim, template< int > class Ref, class Comm, int codim >
71 struct hasEntity< SPGrid< ct, dim, Ref, Comm >, codim >
72 {
75 static const bool v = ((codim >= 0) && (codim <= dim));
76 };
77
83 template< class ct, int dim, template< int > class Ref, class Comm, int codim >
84 struct hasEntityIterator< SPGrid< ct, dim, Ref, Comm >, codim >
85 : public hasEntity< SPGrid< ct, dim, Ref, Comm >, codim >
86 {
87 };
88
89#if HAVE_MPI
98 template< class ct, int dim, template< int > class Ref, int codim >
99 struct canCommunicate< SPGrid< ct, dim, Ref, MPI_Comm >, codim >
100 {
103 static const bool v = ((codim >= 0) && (codim <= dim));
104 };
105#endif // #if HAVE_MPI
106
111 template< class ct, int dim, template< int > class Ref, class Comm >
112 struct isLevelwiseConforming< SPGrid< ct, dim, Ref, Comm > >
113 {
115 static const bool v = true;
116 };
117
122 template< class ct, int dim, template< int > class Ref, class Comm >
123 struct isLeafwiseConforming< SPGrid< ct, dim, Ref, Comm > >
124 {
126 static const bool v = true;
127 };
128
133 template< class ct, int dim, template< int > class Ref, class Comm >
134 struct hasBackupRestoreFacilities< SPGrid< ct, dim, Ref, Comm > >
135 {
137 static const bool v = true;
138 };
139
144 template< class ct, int dim, template< int > class Ref, class Comm >
145 struct threadSafe< SPGrid< ct, dim, Ref, Comm > >
146 {
148 static const bool v = false;
149 };
150
155 template< class ct, int dim, template< int > class Ref, class Comm >
156 struct viewThreadSafe< SPGrid< ct, dim, Ref, Comm > >
157 {
159 static const bool v = false;
160 };
161
162
163
164 // non-standard capabilities (see dune-fem)
165 // ----------------------------------------
166
167 template< class Grid >
169
170 template< class ct, int dim, template< int > class Ref, class Comm >
171 struct hasHierarchicIndexSet< SPGrid< ct, dim, Ref, Comm > >
172 {
173 static const bool v = true;
174 };
175
176
177 template< class Grid >
179
186 template< class ct, int dim, template< int > class Ref, class Comm >
187 struct supportsCallbackAdaptation< SPGrid< ct, dim, Ref, Comm > >
188 {
190 static const bool v = true;
191 };
192
193 } // namespace Capabilities
194
195
196
197 // Extensions
198 // ----------
199
200 namespace Extensions
201 {
202
208 template< class ct, int dim, template< int > class Ref, class Comm, int codim >
209 struct SuperEntityIterator< SPGrid< ct, dim, Ref, Comm >, codim >
210 {
213 static const bool v = ((codim >= 0) && (codim <= dim));
214 };
215
216 } // namespace Extensions
217
218} // namespace Dune
219
220#endif // #ifndef DUNE_SPGRID_CAPABILITIES_HH
Definition: iostream.hh:7
Does a grid support superentity iterators of a codimension?
Definition: extensions/superentityiterator.hh:82
static const bool v
by default, a grid does not support superentity iterators
Definition: extensions/superentityiterator.hh:84
Definition: capabilities.hh:168
Definition: capabilities.hh:178
structured, parallel DUNE grid
Definition: grid.hh:136
interface classes for superentity iterators