dune-grid  2.2.0
alugrid/2d/capabilities.hh
Go to the documentation of this file.
1 #ifndef DUNE_ALU2DGRID_CAPABILITIES_HH
2 #define DUNE_ALU2DGRID_CAPABILITIES_HH
3 
4 // only include this code, if ENABLE_ALUGRID is defined
5 #ifdef ENABLE_ALUGRID
6 
7 #include <dune/geometry/genericgeometry/topologytypes.hh>
8 
12 
13 
19 namespace Dune
20 {
21 
22  template< int dim, int dimworld >
23  class ALUSimplexGrid;
24 
25  template< int dim, int dimw >
26  class ALUCubeGrid;
27 
28  template< int dim, int dimworld >
29  class ALUConformGrid;
30 
31 
32 
33  namespace Capabilities
34  {
35 
36 
37  // Capabilities for ALUSimplexGrid
38  // -------------------------------
39 
43  template< int dimworld >
44  struct hasSingleGeometryType< ALUSimplexGrid< 2, dimworld > >
45  {
46  static const bool v = true;
47  static const unsigned int topologyId = GenericGeometry :: SimplexTopology< 2 > :: type :: id ;
48  };
49 
50 
54  template< int dimworld, int cdim >
55  struct hasEntity< ALUSimplexGrid< 2, dimworld >, cdim >
56  {
57  static const bool v = true;
58  };
59 
60 #if ALU2DGRID_PARALLEL
61 
64  //- default is false
65  template< int dimworld >
66  struct isParallel< ALUSimplexGrid< 2, dimworld > >
67  {
68  static const bool v = true;
69  };
70 #endif // #if ALU2DGRID_PARALLEL
71 
72 #if ALU2DGRID_PARALLEL
73 
76  //- default is false
77  template< int dimworld >
78  struct canCommunicate< ALUSimplexGrid< 2, dimworld >, 0 >
79  {
80  static const bool v = true;
81  };
82 #endif // #if ALU2DGRID_PARALLEL
83 
87  template< int dimworld >
88  struct isLevelwiseConforming< ALUSimplexGrid< 2, dimworld > >
89  {
90  static const bool v = true;
91  };
92 
96  template< int dimworld >
97  struct hasBackupRestoreFacilities< ALUSimplexGrid< 2, dimworld > >
98  {
99  static const bool v = true;
100  };
101 
102 
103 
104  // Capabilities for ALUCubeGrid
105  // ----------------------------
106 
110  template< int wdim >
111  struct hasSingleGeometryType< ALUCubeGrid< 2, wdim > >
112  {
113  static const bool v = true;
114  static const unsigned int topologyId = GenericGeometry :: CubeTopology< 2 > :: type :: id ;
115  };
116 
120  template< int wdim, int cdim >
121  struct hasEntity< Dune::ALUCubeGrid< 2, wdim >, cdim >
122  {
123  static const bool v = true;
124  };
125 
126 #if ALU2DGRID_PARALLEL
127 
130  //- default is false
131  template< int dimworld >
132  struct isParallel< ALUCubeGrid< 2, dimworld > >
133  {
134  static const bool v = true;
135  };
136 #endif // #if ALU2DGRID_PARALLEL
137 
138 #if ALU2DGRID_PARALLEL
139 
142  //- default is false
143  template< int dimworld >
144  struct canCommunicate< ALUCubeGrid< 2, dimworld >, 0 >
145  {
146  static const bool v = true;
147  };
148 #endif // #if ALU2DGRID_PARALLEL
149 
153  template<int wdim>
154  struct isLevelwiseConforming< Dune::ALUCubeGrid< 2, wdim > >
155  {
156  static const bool v = true;
157  };
158 
162  template<int wdim>
163  struct hasBackupRestoreFacilities< Dune::ALUCubeGrid< 2, wdim > >
164  {
165  static const bool v = true;
166  };
167 
168 
169 
170  // Capabilities for ALUConformGrid
171  // -------------------------------
172 
176  template< int dimworld >
177  struct hasSingleGeometryType< ALUConformGrid< 2, dimworld > >
178  {
179  static const bool v = true;
180  static const unsigned int topologyId = GenericGeometry :: SimplexTopology< 2 > :: type :: id ;
181  };
182 
186  template< int dimworld, int cdim >
187  struct hasEntity< ALUConformGrid< 2, dimworld >, cdim >
188  {
189  static const bool v = true;
190  };
191 
192 #if ALU2DGRID_PARALLEL
193 
196  //- default is false
197  template< int dimworld >
198  struct isParallel< ALUConformGrid< 2, dimworld > >
199  {
200  static const bool v = true;
201  };
202 #endif // #if ALU2DGRID_PARALLEL
203 
204 #if ALU2DGRID_PARALLEL
205 
208  //- default is false
209  template< int dimworld >
210  struct canCommunicate< ALUConformGrid< 2, dimworld >, 0 >
211  {
212  static const bool v = true;
213  };
214 #endif // #if ALU2DGRID_PARALLEL
215 
219  template< int dimworld >
220  struct isLeafwiseConforming< ALUConformGrid< 2, dimworld > >
221  {
222  static const bool v = true;
223  };
224 
228  template< int dimworld >
230  {
231  static const bool v = true;
232  };
233 
234  } // namespace Capabilities
235 
236 } // namespace Dune
237 
238 #endif // #ifdef ENABLE_ALUGRID
239 
240 #endif // #ifndef DUNE_ALU2DGRID_CAPABILITIES_HH