wallPolyPatch.H
Go to the documentation of this file.
1/*---------------------------------------------------------------------------*\
2 ========= |
3 \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
4 \\ / O peration |
5 \\ / A nd | www.openfoam.com
6 \\/ M anipulation |
7-------------------------------------------------------------------------------
8 Copyright (C) 2011-2012 OpenFOAM Foundation
9-------------------------------------------------------------------------------
10License
11 This file is part of OpenFOAM.
12
13 OpenFOAM is free software: you can redistribute it and/or modify it
14 under the terms of the GNU General Public License as published by
15 the Free Software Foundation, either version 3 of the License, or
16 (at your option) any later version.
17
18 OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
19 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
20 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
21 for more details.
22
23 You should have received a copy of the GNU General Public License
24 along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
25
26Class
27 Foam::wallPolyPatch
28
29Description
30 Foam::wallPolyPatch
31
32SourceFiles
33 wallPolyPatch.C
34
35\*---------------------------------------------------------------------------*/
36
37#ifndef wallPolyPatch_H
38#define wallPolyPatch_H
39
40#include "polyPatch.H"
41
42// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
43
44namespace Foam
45{
46
47/*---------------------------------------------------------------------------*\
48 Class wallPolyPatch Declaration
49\*---------------------------------------------------------------------------*/
51class wallPolyPatch
52:
53 public polyPatch
54{
55public:
56
57 //- Runtime type information
58 TypeName("wall");
59
60
61 // Constructors
62
63 //- Construct from components
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 //- Construct from dictionary
76 (
77 const word& name,
78 const dictionary& dict,
79 const label index,
80 const polyBoundaryMesh& bm,
81 const word& patchType
82 );
83
84 //- Construct as copy, resetting the boundary mesh
86
87 //- Construct given the original patch and resetting the
88 // face list and boundary mesh information
90 (
91 const wallPolyPatch& pp,
92 const polyBoundaryMesh& bm,
93 const label index,
94 const label newSize,
95 const label newStart
96 );
97
98 //- Construct given the original patch and a map
100 (
101 const wallPolyPatch& pp,
102 const polyBoundaryMesh& bm,
103 const label index,
104 const labelUList& mapAddressing,
105 const label newStart
106 );
107
108 //- Construct and return a clone, resetting the boundary mesh
109 virtual autoPtr<polyPatch> clone(const polyBoundaryMesh& bm) const
110 {
111 return autoPtr<polyPatch>(new wallPolyPatch(*this, bm));
112 }
113
114 //- Construct and return a clone, resetting the face list
115 // and boundary mesh
117 (
118 const polyBoundaryMesh& bm,
119 const label index,
120 const label newSize,
121 const label newStart
122 ) const
123 {
124 return autoPtr<polyPatch>
125 (
126 new wallPolyPatch(*this, bm, index, newSize, newStart)
127 );
128 }
129
130 //- Construct and return a clone, resetting the face list
131 // and boundary mesh
133 (
134 const polyBoundaryMesh& bm,
135 const label index,
136 const labelUList& mapAddressing,
137 const label newStart
138 ) const
139 {
140 return autoPtr<polyPatch>
141 (
142 new wallPolyPatch(*this, bm, index, mapAddressing, newStart)
143 );
144 }
145};
146
147
148// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
149
150} // End namespace Foam
151
152// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
153
154#endif
155
156// ************************************************************************* //
Pointer management similar to std::unique_ptr, with some additional methods and type checking.
Definition: autoPtr.H:66
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
Definition: dictionary.H:126
label index() const noexcept
The index of this patch in the boundaryMesh.
const word & name() const noexcept
The patch name.
A polyBoundaryMesh is a polyPatch list with additional search methods and registered IO.
A patch is a list of labels that address the faces in the global face list.
Definition: polyPatch.H:75
friend class polyBoundaryMesh
Definition: polyPatch.H:99
label start() const
Return start label of this patch in the polyMesh face list.
Definition: polyPatch.H:364
Foam::wallPolyPatch.
Definition: wallPolyPatch.H:53
virtual autoPtr< polyPatch > clone(const polyBoundaryMesh &bm) const
Construct and return a clone, resetting the boundary mesh.
TypeName("wall")
Runtime type information.
A class for handling words, derived from Foam::string.
Definition: word.H:68
Namespace for OpenFOAM.
UList< label > labelUList
A UList of labels.
Definition: UList.H:85
dictionary dict
#define TypeName(TypeNameString)
Declare a ClassName() with extra virtual type info.
Definition: typeInfo.H:73