Chombo + EB + MF  3.2
CFRegion.H
Go to the documentation of this file.
1 #ifdef CH_LANG_CC
2 /*
3  * _______ __
4  * / ___/ / ___ __ _ / / ___
5  * / /__/ _ \/ _ \/ V \/ _ \/ _ \
6  * \___/_//_/\___/_/_/_/_.__/\___/
7  * Please refer to Copyright.txt, in Chombo's root directory.
8  */
9 #endif
10 
11 #ifndef _CFREGION_H_
12 #define _CFREGION_H_
13 
14 #include "REAL.H"
15 #include "BaseFab.H"
16 #include "FArrayBox.H"
17 #include "LayoutData.H"
18 #include "DisjointBoxLayout.H"
19 #include "CFIVS.H"
20 #include "NamespaceHeader.H"
21 
22 
23 /// Class that represents the edge region around a DisjointBoxLayout
24 /**
25 
26 
27  */
28 class CFRegion
29 {
30 public:
31 
32  ///
33  /**
34  Default constructor. User must subsequently call define().
35  */
37  {
38  }
39 
40  ///
41  /**
42  Destructor.
43  */
44  virtual ~CFRegion()
45  {
46  }
47 
48  CFRegion(const CFRegion& a_rhs)
49  {
50  *this = a_rhs;
51  }
52 
53  ///
54  /**
55  Defining constructor. Constructs a valid object.
56  Equivalent to default construction followed by define().
57 
58  */
59  CFRegion(const DisjointBoxLayout& a_grids,
60  const ProblemDomain& a_domain)
61  {
62  define(a_grids, a_domain);
63  }
64  ///
65  /**
66  Defines this object. Existing information is overriden.
67  */
68  void
69  define(const DisjointBoxLayout& a_grids,
70  const ProblemDomain& a_domain);
71 
72 
73  const CFRegion& operator=(const CFRegion& a_rhs);
74 
75  const CFIVS& loCFIVS(const DataIndex& a_dit, int dir);
76  const CFIVS& hiCFIVS(const DataIndex& a_dit, int dir);
77 
78  void coarsen(int refRatio);
79 
80 protected:
81 
84  bool m_defined;
85 };
86 
87 #include "NamespaceFooter.H"
88 #endif
LayoutData< CFIVS > m_loCFIVS[SpaceDim]
Definition: CFRegion.H:82
A class to facilitate interaction with physical boundary conditions.
Definition: ProblemDomain.H:141
Internal class to find parts of a box outside the valid region of a level.
Definition: CFIVS.H:37
bool m_defined
Definition: CFRegion.H:84
const CFIVS & hiCFIVS(const DataIndex &a_dit, int dir)
const int SpaceDim
Definition: SPACE.H:38
CFRegion(const DisjointBoxLayout &a_grids, const ProblemDomain &a_domain)
Definition: CFRegion.H:59
A BoxLayout that has a concept of disjointedness.
Definition: DisjointBoxLayout.H:30
Class that represents the edge region around a DisjointBoxLayout.
Definition: CFRegion.H:28
const CFIVS & loCFIVS(const DataIndex &a_dit, int dir)
Definition: DataIndex.H:114
CFRegion()
Definition: CFRegion.H:36
const CFRegion & operator=(const CFRegion &a_rhs)
CFRegion(const CFRegion &a_rhs)
Definition: CFRegion.H:48
virtual ~CFRegion()
Definition: CFRegion.H:44
LayoutData< CFIVS > m_hiCFIVS[SpaceDim]
Definition: CFRegion.H:83
void define(const DisjointBoxLayout &a_grids, const ProblemDomain &a_domain)
void coarsen(int refRatio)