PatchIntersection.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) 2023 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::PatchIntersection
26 
27 Description
28  Base class for patch intersections. Provides storage and access to the
29  intersection points and faces and their relationship between the source and
30  target patches.
31 
32 SourceFiles
33  PatchIntersectionI.H
34  PatchIntersection.C
35 
36 \*---------------------------------------------------------------------------*/
37 
38 #ifndef PatchIntersection_H
39 #define PatchIntersection_H
40 
41 #include "patchIntersection.H"
42 #include "pointField.H"
43 #include "faceList.H"
44 
45 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
46 
47 namespace Foam
48 {
49 
50 /*---------------------------------------------------------------------------*\
51  Class PatchIntersection Declaration
52 \*---------------------------------------------------------------------------*/
53 
54 template<class SrcPatchType, class TgtPatchType>
56 :
57  public patchIntersection
58 {
59 protected:
60 
61  // Protected Data
62 
63  //- Reference to the source patch
64  const SrcPatchType& srcPatch_;
65 
66  //- Reference to the target patch
67  const TgtPatchType& tgtPatch_;
68 
69 
70 public:
71 
72  // Constructors
73 
74  //- Construct from a source and a target patch
76  (
77  const SrcPatchType& srcPatch,
78  const TgtPatchType& tgtPatch
79  );
80 
81 
82  //- Destructor
83  virtual ~PatchIntersection();
84 
85 
86  // Member Functions
87 
88  // Access
89 
90  //- The source patch
91  inline const SrcPatchType& srcPatch() const;
92 
93  //- The target patch
94  inline const TgtPatchType& tgtPatch() const;
95 };
96 
97 
98 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
99 
100 } // End namespace Foam
101 
102 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
103 
104 #include "PatchIntersectionI.H"
105 
106 #ifdef NoRepository
107  #include "PatchIntersection.C"
108 #endif
109 
110 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
111 
112 #endif
113 
114 // ************************************************************************* //
Base class for patch intersections. Provides storage and access to the intersection points and faces ...
const SrcPatchType & srcPatch() const
The source patch.
const SrcPatchType & srcPatch_
Reference to the source patch.
virtual ~PatchIntersection()
Destructor.
const TgtPatchType & tgtPatch() const
The target patch.
PatchIntersection(const SrcPatchType &srcPatch, const TgtPatchType &tgtPatch)
Construct from a source and a target patch.
const TgtPatchType & tgtPatch_
Reference to the target patch.
Base class for patch intersections. Provides type name and debugging. See templated derivatives for a...
Namespace for OpenFOAM.