nonConformalErrorPolyPatch.C
Go to the documentation of this file.
1 /*---------------------------------------------------------------------------*\
2  ========= |
3  \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
4  \\ / O peration | Website: https://openfoam.org
5  \\ / A nd | Copyright (C) 2021-2022 OpenFOAM Foundation
6  \\/ M anipulation |
7 -------------------------------------------------------------------------------
8 License
9  This file is part of OpenFOAM.
10 
11  OpenFOAM is free software: you can redistribute it and/or modify it
12  under the terms of the GNU General Public License as published by
13  the Free Software Foundation, either version 3 of the License, or
14  (at your option) any later version.
15 
16  OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
17  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
18  FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
19  for more details.
20 
21  You should have received a copy of the GNU General Public License
22  along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
23 
24 \*---------------------------------------------------------------------------*/
25 
28 #include "polyBoundaryMesh.H"
29 #include "polyMesh.H"
30 #include "SubField.H"
31 
32 // * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
33 
34 namespace Foam
35 {
36  defineTypeNameAndDebug(nonConformalErrorPolyPatch, 0);
37 
38  addToRunTimeSelectionTable(polyPatch, nonConformalErrorPolyPatch, word);
40  (
41  polyPatch,
42  nonConformalErrorPolyPatch,
43  dictionary
44  );
45 }
46 
47 
48 // * * * * * * * * * * * * Protected Member Functions * * * * * * * * * * * //
49 
51 {
53 }
54 
55 
57 {
58  nonConformalPolyPatch::reorder(newToOldIndex);
59 }
60 
61 
62 // * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * * //
63 
65 (
66  const word& name,
67  const label size,
68  const label start,
69  const label index,
70  const polyBoundaryMesh& bm,
71  const word& patchType
72 )
73 :
74  polyPatch(name, size, start, index, bm, patchType),
75  nonConformalPolyPatch(static_cast<const polyPatch&>(*this))
76 {}
77 
78 
80 (
81  const word& name,
82  const label size,
83  const label start,
84  const label index,
85  const polyBoundaryMesh& bm,
86  const word& patchType,
87  const word& origPatchName
88 )
89 :
90  polyPatch(name, size, start, index, bm, patchType),
91  nonConformalPolyPatch(*this, origPatchName)
92 {}
93 
94 
96 (
97  const word& name,
98  const dictionary& dict,
99  const label index,
100  const polyBoundaryMesh& bm,
101  const word& patchType
102 )
103 :
104  polyPatch(name, dict, index, bm, patchType),
105  nonConformalPolyPatch(*this, dict)
106 {}
107 
108 
110 (
111  const nonConformalErrorPolyPatch& pp,
112  const polyBoundaryMesh& bm
113 )
114 :
115  polyPatch(pp, bm),
116  nonConformalPolyPatch(*this, pp)
117 {}
118 
119 
121 (
122  const nonConformalErrorPolyPatch& pp,
123  const polyBoundaryMesh& bm,
124  const label index,
125  const label newSize,
126  const label newStart,
127  const word& origPatchName
128 )
129 :
130  polyPatch(pp, bm, index, newSize, newStart),
131  nonConformalPolyPatch(*this, origPatchName)
132 {}
133 
134 
136 (
137  const nonConformalErrorPolyPatch& pp,
138  const polyBoundaryMesh& bm,
139  const label index,
140  const labelUList& mapAddressing,
141  const label newStart
142 )
143 :
144  polyPatch(pp, bm, index, mapAddressing, newStart),
145  nonConformalPolyPatch(*this, pp)
146 {}
147 
148 
149 // * * * * * * * * * * * * * * * * Destructor * * * * * * * * * * * * * * * //
150 
152 {}
153 
154 
155 // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
156 
158 {
159  polyPatch::write(os);
161 }
162 
163 
164 // ************************************************************************* //
A list of keyword definitions, which are a keyword followed by any number of values (e...
Definition: dictionary.H:156
Macros for easy insertion into run-time selection tables.
nonConformalErrorPolyPatch(const word &name, const label size, const label start, const label index, const polyBoundaryMesh &bm, const word &patchType)
Construct from components.
virtual void write(Ostream &) const
Write the polyPatch data as a dictionary.
Definition: polyPatch.C:382
A class for handling words, derived from string.
Definition: word.H:59
Non-conformal poly patch. This patch is a placeholder and must have no faces. This patch is linked to...
A 1D vector of objects of type <T>, where the size of the vector is known and can be used for subscri...
Definition: HashTable.H:60
Foam::polyBoundaryMesh.
An Ostream is an abstract base class for all output systems (streams, files, token lists...
Definition: Ostream.H:54
virtual void rename(const wordList &newNames)
Reset the patch name.
addToRunTimeSelectionTable(ensightPart, ensightPartCells, istream)
Non-conformal error poly patch. As nonConformalPolyPatch. This patch is a non-coupled non-conformal p...
defineTypeNameAndDebug(combustionModel, 0)
virtual void write(Ostream &) const
Write the polyPatch data as a dictionary.
virtual void reorder(const labelUList &newToOldIndex)
Reset the patch index.
virtual void rename(const wordList &newNames)
Reset the patch name.
virtual void reorder(const labelUList &newToOldIndex)
Reset the patch index.
A patch is a list of labels that address the faces in the global face list.
Definition: polyPatch.H:66
virtual void write(Ostream &) const
Write the polyPatch data as a dictionary.
Namespace for OpenFOAM.