Loading...
Searching...
No Matches
pointFields.C
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) 2025 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
27\*---------------------------------------------------------------------------*/
28
29#include "polyMesh.H"
30#include "pointFields.H"
33// * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
35namespace Foam
36{
37
43
49
52(
54 "pointScalarField::Boundary",
55 0
56);
58(
60 "pointVectorField::Boundary",
61 0
62);
64(
66 "pointSphericalTensorField::Boundary",
67 0
68);
70(
72 "pointSymmTensorField::Boundary",
73 0
74);
76(
78 "pointTensorField::Boundary",
79 0
80);
81
82} // End namespace Foam
83
84
85// * * * * * * * * * * * * * * * * Global Data * * * * * * * * * * * * * * * //
86
87// Note hard-coded values are more reliable than other alternatives
88
90({
91 "pointScalarField",
92 "pointVectorField",
93 "pointSphericalTensorField",
94 "pointSymmTensorField",
95 "pointTensorField"
96});
97
98
99// * * * * * * * * * * * * * * * Global Functions * * * * * * * * * * * * * //
100
101bool Foam::fieldTypes::is_point(const word& clsName)
102{
103 return
104 (
105 clsName.starts_with("point") && clsName.ends_with("Field")
106 && Foam::fieldTypes::point.contains(clsName)
107 );
108}
109
110
111// ************************************************************************* //
GeometricBoundaryField< scalar, pointPatchField, pointMesh > Boundary
bool ends_with(char c) const
True if string ends with given character (cf. C++20).
Definition string.H:461
bool starts_with(char c) const
True if string starts with given character (cf. C++20).
Definition string.H:436
A class for handling words, derived from Foam::string.
Definition word.H:66
#define defineTemplateTypeNameAndDebug(Type, DebugSwitch)
Define the typeName and debug information for templates, useful.
Definition className.H:158
#define defineTemplateDebugSwitchWithName(Type, Name, Value)
Define the debug information for templates, lookup as Name.
const wordList point
Standard point field types (scalar, vector, tensor, etc).
bool is_point(const word &clsName)
Test if the class name appears to be a point field.
Definition pointFields.C:94
Namespace for OpenFOAM.
List< word > wordList
List of word.
Definition fileName.H:60
GeometricField< tensor, pointPatchField, pointMesh > pointTensorField
GeometricField< scalar, pointPatchField, pointMesh > pointScalarField
GeometricField< sphericalTensor, pointPatchField, pointMesh > pointSphericalTensorField
GeometricField< vector, pointPatchField, pointMesh > pointVectorField
GeometricField< symmTensor, pointPatchField, pointMesh > pointSymmTensorField