Reference documentation for deal.II version 9.2.0
\(\newcommand{\dealvcentcolon}{\mathrel{\mathop{:}}}\) \(\newcommand{\dealcoloneq}{\dealvcentcolon\mathrel{\mkern-1.2mu}=}\) \(\newcommand{\jump}[1]{\left[\!\left[ #1 \right]\!\right]}\) \(\newcommand{\average}[1]{\left\{\!\left\{ #1 \right\}\!\right\}}\)
grid_tools_cache_update_flags.h
Go to the documentation of this file.
1 // ---------------------------------------------------------------------
2 //
3 // Copyright (C) 2017 - 2019 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.md at
12 // the top level directory of deal.II.
13 //
14 // ---------------------------------------------------------------------
15 
16 #ifndef dealii_grid_tria_info_cache_update_flags_h
17 #define dealii_grid_tria_info_cache_update_flags_h
18 
19 
20 #include <deal.II/base/config.h>
21 
23 
24 namespace GridTools
25 {
36  {
40  update_nothing = 0x000,
41 
47 
54 
60 
65 
70 
75 
85 
89  update_all = 0x0FF,
90  };
91 
92 
98  template <class StreamType>
99  inline StreamType &
100  operator<<(StreamType &s, const CacheUpdateFlags u)
101  {
102  s << " CacheUpdateFlags";
104  s << "|vertex_to_cell_map";
106  s << "|vertex_to_cells_centers_directions";
107  if (u & update_covering_rtree)
108  s << "|covering_rtree";
109 #ifdef DEAL_II_WITH_NANOFLANN
110  if (u & update_vertex_kdtree)
111  s << "|vertex_kdtree";
112 #endif
113  return s;
114  }
115 
116 
126  inline CacheUpdateFlags
128  {
129  return static_cast<CacheUpdateFlags>(static_cast<unsigned int>(f1) |
130  static_cast<unsigned int>(f2));
131  }
132 
142  inline CacheUpdateFlags
144  {
145  return static_cast<CacheUpdateFlags>(static_cast<unsigned int>(f1) ^
146  static_cast<unsigned int>(update_all));
147  }
148 
149 
150 
157  inline CacheUpdateFlags &
159  {
160  f1 = f1 | f2;
161  return f1;
162  }
163 
164 
175  const CacheUpdateFlags f2)
176  {
177  return static_cast<CacheUpdateFlags>(static_cast<unsigned int>(f1) &
178  static_cast<unsigned int>(f2));
179  }
180 
181 
188  inline CacheUpdateFlags &
190  {
191  f1 = f1 & f2;
192  return f1;
193  }
194 
195 } // namespace GridTools
197 
198 #endif
GridTools::update_vertex_to_cell_centers_directions
@ update_vertex_to_cell_centers_directions
Definition: grid_tools_cache_update_flags.h:52
GridTools
Definition: grid_tools.h:125
GridTools::operator|=
CacheUpdateFlags & operator|=(CacheUpdateFlags &f1, const CacheUpdateFlags f2)
Definition: grid_tools_cache_update_flags.h:158
GridTools::update_all
@ update_all
Definition: grid_tools_cache_update_flags.h:89
GridTools::update_used_vertices_rtree
@ update_used_vertices_rtree
Definition: grid_tools_cache_update_flags.h:69
GridTools::CacheUpdateFlags
CacheUpdateFlags
Definition: grid_tools_cache_update_flags.h:35
GridTools::operator~
CacheUpdateFlags operator~(const CacheUpdateFlags f1)
Definition: grid_tools_cache_update_flags.h:143
GridTools::update_used_vertices
@ update_used_vertices
Definition: grid_tools_cache_update_flags.h:64
GridTools::operator&=
CacheUpdateFlags & operator&=(CacheUpdateFlags &f1, const CacheUpdateFlags f2)
Definition: grid_tools_cache_update_flags.h:189
GridTools::update_covering_rtree
@ update_covering_rtree
Definition: grid_tools_cache_update_flags.h:84
DEAL_II_NAMESPACE_OPEN
#define DEAL_II_NAMESPACE_OPEN
Definition: config.h:358
GridTools::operator|
CacheUpdateFlags operator|(const CacheUpdateFlags f1, const CacheUpdateFlags f2)
Definition: grid_tools_cache_update_flags.h:127
GridTools::operator&
CacheUpdateFlags operator&(const CacheUpdateFlags f1, const CacheUpdateFlags f2)
Definition: grid_tools_cache_update_flags.h:174
GridTools::update_vertex_kdtree
@ update_vertex_kdtree
Definition: grid_tools_cache_update_flags.h:59
GridTools::update_vertex_to_cell_map
@ update_vertex_to_cell_map
Definition: grid_tools_cache_update_flags.h:46
config.h
DEAL_II_NAMESPACE_CLOSE
#define DEAL_II_NAMESPACE_CLOSE
Definition: config.h:359
GridTools::update_nothing
@ update_nothing
Definition: grid_tools_cache_update_flags.h:40
GridTools::update_cell_bounding_boxes_rtree
@ update_cell_bounding_boxes_rtree
Definition: grid_tools_cache_update_flags.h:74
GridTools::operator<<
StreamType & operator<<(StreamType &s, const CacheUpdateFlags u)
Definition: grid_tools_cache_update_flags.h:100