Loading...
Searching...
No Matches
genericPointPatchField.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-2016 OpenFOAM Foundation
9 Copyright (C) 2016-2021 OpenCFD Ltd.
10-------------------------------------------------------------------------------
11License
12 This file is part of OpenFOAM.
13
14 OpenFOAM is free software: you can redistribute it and/or modify it
15 under the terms of the GNU General Public License as published by
16 the Free Software Foundation, either version 3 of the License, or
17 (at your option) any later version.
18
19 OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
20 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
21 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
22 for more details.
23
24 You should have received a copy of the GNU General Public License
25 along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
26
27Class
28 Foam::genericPointPatchField
29
30Description
31 A generic version of calculatedPointPatchField, useful as a fallback for
32 handling unknown patch types.
33
34SourceFiles
35 genericPointPatchField.C
36
37\*---------------------------------------------------------------------------*/
38
39#ifndef Foam_genericPointPatchField_H
40#define Foam_genericPointPatchField_H
41
44
45// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
46
47namespace Foam
48{
49
50/*---------------------------------------------------------------------------*\
51 Class genericPointPatchField Declaration
52\*---------------------------------------------------------------------------*/
53
54template<class Type>
56:
57 public calculatedPointPatchField<Type>,
59{
60 //- The parent boundary condition type
61 typedef calculatedPointPatchField<Type> parent_bctype;
62
63
64public:
65
66 //- Runtime type information
67 TypeName("generic");
68
69
70 // Constructors
71
72 //- Construct from patch and internal field
74 (
75 const pointPatch&,
77 );
78
79 //- Construct from patch, internal field and dictionary
81 (
82 const pointPatch&,
84 const dictionary&
85 );
86
87 //- Construct by mapping given patch field onto a new patch
89 (
91 const pointPatch&,
94 );
95
96 //- Default copy construct
98
99 //- Construct as copy setting internal field reference
101 (
104 );
105
106 //- Return a clone
107 virtual autoPtr<pointPatchField<Type>> clone() const
108 {
109 return pointPatchField<Type>::Clone(*this);
110 }
111
112 //- Construct and return a clone setting internal field reference
114 (
116 ) const
117 {
119 }
120
121
122 // Member Functions
123
124 //- Write
125 virtual void write(Ostream&) const;
127
128 // Mapping Functions
129
130 //- Map (and resize as needed) from self given a mapping object
131 virtual void autoMap(const pointPatchFieldMapper&);
132
133 //- Reverse map the given pointPatchField onto this pointPatchField
134 virtual void rmap
135 (
137 const labelList&
138 );
139};
140
141
142// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
143
144} // End namespace Foam
145
146// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
147
148#ifdef NoRepository
149 #include "genericPointPatchField.C"
150#endif
151
152// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
153
154#endif
155
156// ************************************************************************* //
Field with dimensions and associated with geometry type GeoMesh which is used to size the field and a...
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
Definition Ostream.H:59
Pointer management similar to std::unique_ptr, with some additional methods and type checking.
Definition autoPtr.H:65
calculatedPointPatchField(const pointPatch &, const DimensionedField< Type, pointMesh > &)
Construct from patch and internal field.
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
Definition dictionary.H:133
genericPatchFieldBase(const Foam::zero, const genericPatchFieldBase &)
Partial copy construct. Only copy type and dictionary.
genericPointPatchField(const pointPatch &, const DimensionedField< Type, pointMesh > &)
Construct from patch and internal field.
TypeName("generic")
Runtime type information.
virtual void autoMap(const pointPatchFieldMapper &)
Map (and resize as needed) from self given a mapping object.
genericPointPatchField(const genericPointPatchField< Type > &)=default
Default copy construct.
virtual autoPtr< pointPatchField< Type > > clone(const DimensionedField< Type, pointMesh > &iF) const
Construct and return a clone setting internal field reference.
virtual autoPtr< pointPatchField< Type > > clone() const
Return a clone.
virtual void rmap(const pointPatchField< Type > &, const labelList &)
Reverse map the given pointPatchField onto this pointPatchField.
Foam::pointPatchFieldMapper.
Abstract base class for point-mesh patch fields.
static autoPtr< pointPatchField< Type > > Clone(const DerivedPatchField &pf, Args &&... args)
Clone a patch field, optionally with internal field reference etc.
Basic pointPatch represents a set of points from the mesh.
Definition pointPatch.H:67
Namespace for OpenFOAM.
List< label > labelList
A List of labels.
Definition List.H:62
runTime write()
#define TypeName(TypeNameString)
Declare a ClassName() with extra virtual type info.
Definition typeInfo.H:68