Reference documentation for deal.II version 9.0.0
assemble_flags.h
1 // ---------------------------------------------------------------------
2 //
3 // Copyright (C) 2017 by the deal.II authors
4 //
5 // This file is part of the deal.II library.
6 //
7 // The deal.II library is free software; you can use it, redistribute
8 // it, and/or modify it under the terms of the GNU Lesser General
9 // Public License as published by the Free Software Foundation; either
10 // version 2.1 of the License, or (at your option) any later version.
11 // The full text of the license can be found in the file LICENSE at
12 // the top level of the deal.II distribution.
13 //
14 // ---------------------------------------------------------------------
15 
16 #ifndef dealii_mesh_worker_assemble_flags_h
17 #define dealii_mesh_worker_assemble_flags_h
18 
19 
20 #include <deal.II/base/config.h>
21 #include <vector>
22 
23 
24 DEAL_II_NAMESPACE_OPEN
25 
28 
29 namespace MeshWorker
30 {
31 
42  {
82 
88 
93 
101 
107  };
108 
109 
115  template <class StreamType>
116  inline
117  StreamType &operator << (StreamType &s, AssembleFlags u)
118  {
119  s << " AssembleFlags";
120  if (u & assemble_own_cells ) s << "|own_cells" ;
121  if (u & assemble_own_interior_faces_once ) s << "|own_faces_once" ;
122  if (u & assemble_own_interior_faces_both ) s << "|own_faces_both" ;
123  if (u & assemble_ghost_cells ) s << "|ghost_cells" ;
124  if (u & assemble_ghost_faces_once ) s << "|ghost_faces_once" ;
125  if (u & assemble_ghost_faces_both ) s << "|ghost_faces_both" ;
126  if (u & assemble_boundary_faces ) s << "|boundary_faces" ;
127  return s;
128  }
129 
130 
140  inline
143  {
144  return static_cast<AssembleFlags> (
145  static_cast<unsigned int> (f1) |
146  static_cast<unsigned int> (f2));
147  }
148 
149 
150 
151 
158  inline
159  AssembleFlags &
161  {
162  f1 = f1 | f2;
163  return f1;
164  }
165 
166 
176  inline
179  {
180  return static_cast<AssembleFlags> (
181  static_cast<unsigned int> (f1) &
182  static_cast<unsigned int> (f2));
183  }
184 
185 
192  inline
193  AssembleFlags &
195  {
196  f1 = f1 & f2;
197  return f1;
198  }
199 }
200 
203 DEAL_II_NAMESPACE_CLOSE
204 
205 #endif
AssembleFlags operator|(AssembleFlags f1, AssembleFlags f2)
AssembleFlags & operator|=(AssembleFlags &f1, AssembleFlags f2)
AssembleFlags & operator&=(AssembleFlags &f1, AssembleFlags f2)
StreamType & operator<<(StreamType &s, AssembleFlags u)
AssembleFlags operator&(AssembleFlags f1, AssembleFlags f2)