extendedFeatureEdgeMesh.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-2022 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::extendedFeatureEdgeMesh
26 
27 Description
28 
29  extendedEdgeMesh + IO.
30 
31 SourceFiles
32  extendedFeatureEdgeMesh.C
33 
34 \*---------------------------------------------------------------------------*/
35 
36 #ifndef extendedFeatureEdgeMesh_H
37 #define extendedFeatureEdgeMesh_H
38 
39 #include "extendedEdgeMesh.H"
40 #include "regIOobject.H"
41 
42 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
43 
44 namespace Foam
45 {
46 
47 class objectRegistry;
48 
49 /*---------------------------------------------------------------------------*\
50  Class extendedFeatureEdgeMesh Declaration
51 \*---------------------------------------------------------------------------*/
52 
54 :
55  public regIOobject,
56  public extendedEdgeMesh
57 {
58 
59 public:
60 
61  //- Runtime type information
62  TypeName("extendedFeatureEdgeMesh");
63 
64 
65  // Constructors
66 
67  //- Construct (read) given an IOobject
69 
70  //- Copy constructor
72  (
73  const IOobject&,
74  const extendedEdgeMesh&
75  );
76 
77  //- Construct given a surface with selected edges,point
78  // (surfaceFeatures), an objectRegistry and a
79  // fileName to write to.
80  // Extracts, classifies and reorders the data from surfaceFeatures.
82  (
83  const surfaceFeatures& sFeat,
84  const objectRegistry& obr,
85  const fileName& sFeatFileName,
86  const boolList& surfBaffleRegions
87  );
88 
89  //- Construct from PrimitivePatch
91  (
92  const IOobject&,
94  const labelList& featureEdges,
95  const labelList& regionFeatureEdges,
96  const labelList& featurePoints
97  );
98 
99  //- Construct from all components
101  (
102  const IOobject& io,
103  const pointField& pts,
104  const edgeList& eds,
112  const vectorField& normals,
116  const labelListList& edgeNormals,
119  const labelList& regionEdges
120  );
121 
122 
123  //- Destructor
124  virtual ~extendedFeatureEdgeMesh();
125 
126 
127  // IO
128 
129  //- Give precedence to the regIOobject write
130  using regIOobject::write;
131 
132  //- ReadData function required for regIOobject read operation
133  virtual bool readData(Istream&);
134 
135  //- WriteData function required for regIOobject write operation
136  virtual bool writeData(Ostream&) const;
137 
138  //- Is object global
139  virtual bool global() const
140  {
141  return true;
142  }
143 };
144 
145 
146 //- Trait for obtaining global status
147 template<>
149 {
150  static const bool global = true;
151 };
152 
153 
154 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
155 
156 } // End namespace Foam
157 
158 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
159 
160 #endif
161 
162 // ************************************************************************* //
IOobject defines the attributes of an object for which implicit objectRegistry management is supporte...
Definition: IOobject.H:99
An Istream is an abstract base class for all input systems (streams, files, token lists etc)....
Definition: Istream.H:60
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
Definition: Ostream.H:57
A list of faces which address into the list of points.
Description of feature edges and points.
const labelListList & normalDirections() const
label openStart() const
Return the index of the start of the open feature edges.
label nonFeatureStart() const
Return the index of the start of the non-feature points.
const vectorField & edgeDirections() const
Return the edgeDirection vectors.
const List< sideVolumeType > & normalVolumeTypes() const
Return.
label flatStart() const
Return the index of the start of the flat feature edges.
const labelListList & featurePointEdges() const
Return the edge labels for a given feature point. Edges are.
const labelList & regionEdges() const
Return the feature edges which are on the boundary between.
const labelListList & edgeNormals() const
Return the indices of the normals that are adjacent to the.
const vectorField & normals() const
Return the normals of the surfaces adjacent to the feature edges.
label multipleStart() const
Return the index of the start of the multiply-connected feature.
label internalStart() const
Return the index of the start of the internal feature edges.
const labelListList & featurePointNormals() const
Return the indices of the normals that are adjacent to the.
label mixedStart() const
Return the index of the start of the mixed type feature points.
label concaveStart() const
Return the index of the start of the concave feature points.
virtual bool writeData(Ostream &) const
WriteData function required for regIOobject write operation.
virtual bool global() const
Is object global.
extendedFeatureEdgeMesh(const IOobject &)
Construct (read) given an IOobject.
TypeName("extendedFeatureEdgeMesh")
Runtime type information.
virtual ~extendedFeatureEdgeMesh()
Destructor.
virtual bool readData(Istream &)
ReadData function required for regIOobject read operation.
A class for handling file names.
Definition: fileName.H:82
Registry of regIOobjects.
regIOobject is an abstract class derived from IOobject to handle automatic object registration with t...
Definition: regIOobject.H:55
virtual bool write(const bool write=true) const
Write using setting from DB.
Holds feature edges/points of surface.
Namespace for OpenFOAM.
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
Trait for obtaining global status.
Definition: IOobject.H:504
static const bool global
Definition: IOobject.H:505