boundaryToFace.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 OpenFOAM Foundation
9  Copyright (C) 2018 OpenCFD Ltd.
10 -------------------------------------------------------------------------------
11 License
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 Class
28  Foam::boundaryToFace
29 
30 Description
31  A topoSetFaceSource to select all external (boundary) faces.
32 
33  \heading Dictionary parameters
34  None
35 
36 SourceFiles
37  boundaryToFace.C
38 
39 \*---------------------------------------------------------------------------*/
40 
41 #ifndef boundaryToFace_H
42 #define boundaryToFace_H
43 
44 #include "topoSetFaceSource.H"
45 
46 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
47 
48 namespace Foam
49 {
50 
51 /*---------------------------------------------------------------------------*\
52  Class boundaryToFace Declaration
53 \*---------------------------------------------------------------------------*/
54 
55 class boundaryToFace
56 :
57  public topoSetFaceSource
58 {
59  // Private data
60 
61  //- Add usage string
62  static addToUsageTable usage_;
63 
64 
65  // Private Member Functions
66 
67  void combine(topoSet& set, const bool add) const;
68 
69 
70 public:
71 
72  //- Runtime type information
73  TypeName("boundaryToFace");
74 
75  // Constructors
76 
77  //- Construct from components
79 
80  //- Construct from dictionary
81  boundaryToFace(const polyMesh& mesh, const dictionary& unused);
82 
83  //- Construct from Istream
84  boundaryToFace(const polyMesh& mesh, Istream& unused);
85 
86 
87  //- Destructor
88  virtual ~boundaryToFace() = default;
89 
90 
91  // Member Functions
92 
93  virtual void applyToSet
94  (
95  const topoSetSource::setAction action,
96  topoSet& set
97  ) const;
98 
99 };
100 
101 
102 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
103 
104 } // End namespace Foam
105 
106 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
107 
108 #endif
109 
110 // ************************************************************************* //
Foam::combine
Definition: FaceCellWave.C:56
Foam::topoSetSource::addToUsageTable
Class with constructor to add usage string to table.
Definition: topoSetSource.H:124
Foam::topoSetSource::setAction
setAction
Enumeration defining the valid actions.
Definition: topoSetSource.H:99
Foam::topoSetFaceSource
Base class of a topoSet source for selecting faces.
Definition: topoSetFaceSource.H:50
Foam::topoSetSource::mesh
const polyMesh & mesh() const
Reference to the mesh.
Definition: topoSetSource.H:333
Foam::polyMesh
Mesh consisting of general polyhedral cells.
Definition: polyMesh.H:77
Foam::boundaryToFace::boundaryToFace
boundaryToFace(const polyMesh &mesh)
Construct from components.
Definition: boundaryToFace.C:85
Foam::boundaryToFace::~boundaryToFace
virtual ~boundaryToFace()=default
Destructor.
Foam::Istream
An Istream is an abstract base class for all input systems (streams, files, token lists etc)....
Definition: Istream.H:61
Foam::topoSet
General set of labels of mesh quantity (points, cells, faces).
Definition: topoSet.H:66
Foam::dictionary
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
Definition: dictionary.H:121
Foam::add
void add(FieldField< Field1, typename typeOfSum< Type1, Type2 >::type > &f, const FieldField< Field1, Type1 > &f1, const FieldField< Field2, Type2 > &f2)
Definition: FieldFieldFunctions.C:939
Foam
Namespace for OpenFOAM.
Definition: atmBoundaryLayer.C:33
Foam::boundaryToFace
A topoSetFaceSource to select all external (boundary) faces.
Definition: boundaryToFace.H:54
Foam::boundaryToFace::applyToSet
virtual void applyToSet(const topoSetSource::setAction action, topoSet &set) const
Apply specified action to the topoSet.
Definition: boundaryToFace.C:114
Foam::boundaryToFace::TypeName
TypeName("boundaryToFace")
Runtime type information.
topoSetFaceSource.H