Reference documentation for deal.II version 9.3.3
\(\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 - 2020 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
24namespace GridTools
25{
34 {
39
45
52
57
62
67
76
81
86
90 update_all = 0xFFF,
91 };
92
93
99 template <class StreamType>
100 inline StreamType &
101 operator<<(StreamType &s, const CacheUpdateFlags u)
102 {
103 s << " CacheUpdateFlags";
105 s << "|vertex_to_cell_map";
107 s << "|vertex_to_cells_centers_directions";
108 if (u & update_covering_rtree)
109 s << "|covering_rtree";
110 return s;
111 }
112
113
123 inline CacheUpdateFlags
125 {
126 return static_cast<CacheUpdateFlags>(static_cast<unsigned int>(f1) |
127 static_cast<unsigned int>(f2));
128 }
129
139 inline CacheUpdateFlags
141 {
142 return static_cast<CacheUpdateFlags>(static_cast<unsigned int>(f1) ^
143 static_cast<unsigned int>(update_all));
144 }
145
146
147
154 inline CacheUpdateFlags &
156 {
157 f1 = f1 | f2;
158 return f1;
159 }
160
161
172 const CacheUpdateFlags f2)
173 {
174 return static_cast<CacheUpdateFlags>(static_cast<unsigned int>(f1) &
175 static_cast<unsigned int>(f2));
176 }
177
178
185 inline CacheUpdateFlags &
187 {
188 f1 = f1 & f2;
189 return f1;
190 }
191
192} // namespace GridTools
194
195#endif
#define DEAL_II_NAMESPACE_OPEN
Definition: config.h:402
#define DEAL_II_NAMESPACE_CLOSE
Definition: config.h:403
CacheUpdateFlags & operator|=(CacheUpdateFlags &f1, const CacheUpdateFlags f2)
CacheUpdateFlags operator|(const CacheUpdateFlags f1, const CacheUpdateFlags f2)
CacheUpdateFlags operator&(const CacheUpdateFlags f1, const CacheUpdateFlags f2)
CacheUpdateFlags operator~(const CacheUpdateFlags f1)
StreamType & operator<<(StreamType &s, const CacheUpdateFlags u)
CacheUpdateFlags & operator&=(CacheUpdateFlags &f1, const CacheUpdateFlags f2)