nonuniformTransformCyclicPolyPatch.H
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) 2011-2018 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 Class
25  Foam::nonuniformTransformCyclicPolyPatch
26 
27 Description
28  Transform boundary used in extruded regions. Allows non-uniform transforms.
29  Wip.
30 
31 SourceFiles
32  nonuniformTransformCyclicPolyPatch.C
33 
34 \*---------------------------------------------------------------------------*/
35 
36 #ifndef nonuniformTransformCyclicPolyPatch_H
37 #define nonuniformTransformCyclicPolyPatch_H
38 
39 #include "cyclicPolyPatch.H"
40 
41 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
42 
43 namespace Foam
44 {
45 
46 /*---------------------------------------------------------------------------*\
47  Class nonuniformTransformCyclicPolyPatch Declaration
48 \*---------------------------------------------------------------------------*/
49 
51 :
52  public cyclicPolyPatch
53 {
54 
55 public:
56 
57  //- Runtime type information
58  TypeName("nonuniformTransformCyclic");
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,
73  )
74  :
75  cyclicPolyPatch(name, size, start, index, bm, patchType, transform)
76  {}
77 
78  //- Construct from dictionary
80  (
81  const word& name,
82  const dictionary& dict,
83  const label index,
84  const polyBoundaryMesh& bm,
85  const word& patchType
86  )
87  :
88  cyclicPolyPatch(name, dict, index, bm, patchType)
89  {}
90 
91  //- Construct as copy, resetting the boundary mesh
93  (
95  const polyBoundaryMesh& bm
96  )
97  :
98  cyclicPolyPatch(pp, bm)
99  {}
100 
101  //- Construct given the original patch and resetting the
102  // face list and boundary mesh information
104  (
106  const polyBoundaryMesh& bm,
107  const label index,
108  const label newSize,
109  const label newStart,
110  const word& neighbPatchName
111  )
112  :
113  cyclicPolyPatch(pp, bm, index, newSize, newStart, neighbPatchName)
114  {}
115 
116  //- Construct given the original patch and a map
118  (
120  const polyBoundaryMesh& bm,
121  const label index,
122  const labelUList& mapAddressing,
123  const label newStart
124  )
125  :
126  cyclicPolyPatch(pp, bm, index, mapAddressing, newStart)
127  {}
128 
129  //- Construct and return a clone, resetting the boundary mesh
130  virtual autoPtr<polyPatch> clone(const polyBoundaryMesh& bm) const
131  {
132  return autoPtr<polyPatch>
133  (
135  );
136  }
137 
138  //- Construct and return a clone, resetting the face list
139  // and boundary mesh
141  (
142  const polyBoundaryMesh& bm,
143  const label index,
144  const label newSize,
145  const label newStart
146  ) const
147  {
148  return autoPtr<polyPatch>
149  (
151  (
152  *this,
153  bm,
154  index,
155  newSize,
156  newStart,
158  )
159  );
160  }
161 
162  //- Construct and return a clone, resetting the face list
163  // and boundary mesh
165  (
166  const polyBoundaryMesh& bm,
167  const label index,
168  const labelUList& mapAddressing,
169  const label newStart
170  ) const
171  {
172  return autoPtr<polyPatch>
173  (
175  (
176  *this,
177  bm,
178  index,
179  mapAddressing,
180  newStart
181  )
182  );
183  }
184 
185 
186  // Destructor
189  {}
190 
191 
192 };
193 
194 
195 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
196 
197 } // End namespace Foam
198 
199 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
200 
201 #endif
202 
203 // ************************************************************************* //
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
Definition: label.H:59
A list of keyword definitions, which are a keyword followed by any number of values (e...
Definition: dictionary.H:158
Transform boundary used in extruded regions. Allows non-uniform transforms. Wip.
virtual autoPtr< PrimitivePatch< FaceList, PointField > > clone() const
Construct and return a clone.
A class for handling words, derived from string.
Definition: word.H:59
Cyclic plane patch.
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.
TypeName("nonuniformTransformCyclic")
Runtime type information.
const word & neighbPatchName() const
Neighbour patch name.
virtual transformType transform() const
Type of transform.
An auto-pointer similar to the STL auto_ptr but with automatic casting to a reference to the type and...
Definition: PtrList.H:52
nonuniformTransformCyclicPolyPatch(const word &name, const label size, const label start, const label index, const polyBoundaryMesh &bm, const word &patchType, const transformType transform=UNKNOWN)
Construct from components.
Namespace for OpenFOAM.