1 /*---------------------------------------------------------------------------*\
3 \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
5 \\ / A nd | Copyright (C) 1991-2008 OpenCFD Ltd.
7 -------------------------------------------------------------------------------
9 This file is part of OpenFOAM.
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 the
13 Free Software Foundation; either version 2 of the License, or (at your
14 option) any later version.
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
21 You should have received a copy of the GNU General Public License
22 along with OpenFOAM; if not, write to the Free Software Foundation,
23 Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
29 Collection of static functions to do various simple patch related things.
34 \*---------------------------------------------------------------------------*/
40 #include "labelList.H"
41 #include "primitivePatch.H"
43 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
48 /*---------------------------------------------------------------------------*\
49 Class walkPatch Declaration
50 \*---------------------------------------------------------------------------*/
56 //- Reference to patch to walk on
57 const primitivePatch& pp_;
59 //- Reference to zones
60 const labelList& faceZone_;
62 //- How to walk through faces
65 //- Reference to list to mark off visited faces
70 DynamicList<label> visitOrder_;
72 // Index in face of vertex it was visited through
73 DynamicList<label> indexInFace_;
76 // Private Member Functions
78 //- Get other face using v0, v1. Returns -1 if none.
87 //- Gets labels of changed faces and enterVertices on faces.
88 // Returns labels of faces changed and enterVertices on them.
91 const labelList& changedFaces,
92 const labelList& enterVerts,
95 labelList& nbrEnterVerts
99 //- Disallow default bitwise copy construct
100 walkPatch(const walkPatch&);
102 //- Disallow default bitwise assignment
103 void operator=(const walkPatch&);
107 ClassName("walkPatch");
112 //- Construct from components
115 const primitivePatch& pp,
116 const labelList& faceZone, // Per face which zone it belongs to
117 const bool reverse, // Reverse walk
118 const label faceI, // Current face
119 const label enterVertI, // Vertex across which this face
127 const DynamicList<label>& visitOrder() const
132 const DynamicList<label>& indexInFace() const
140 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
142 } // End namespace Foam
144 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
148 // ************************************************************************* //