initial commit for version 1.5.x patch release
[OpenFOAM-1.5.x.git] / applications / utilities / parallelProcessing / reconstructPar / processorMeshes.H
blob4c47b499d232cc9572c7cb062bd294d87098d639
1 /*---------------------------------------------------------------------------*\
2   =========                 |
3   \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox
4    \\    /   O peration     |
5     \\  /    A nd           | Copyright (C) 1991-2008 OpenCFD Ltd.
6      \\/     M anipulation  |
7 -------------------------------------------------------------------------------
8 License
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
19     for more details.
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
25 Class
26     Foam::processorMeshes
28 Description
29     Container for processor mesh addressing.
31 SourceFiles
32     processorMeshes.C
34 \*---------------------------------------------------------------------------*/
36 #ifndef processorMeshes_H
37 #define processorMeshes_H
39 #include "PtrList.H"
40 #include "fvMesh.H"
41 #include "IOobjectList.H"
42 #include "labelIOList.H"
44 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
46 namespace Foam
50 /*---------------------------------------------------------------------------*\
51                      Class processorMeshes Declaration
52 \*---------------------------------------------------------------------------*/
54 class processorMeshes
56     // Private data
58         //- Processor databases
59         PtrList<Time>& databases_;
61         const word meshName_;
63         //- List of processor meshes
64         PtrList<fvMesh> meshes_;
66         //- List of processor point addressing lists
67         PtrList<labelIOList> pointProcAddressing_;
69         //- List of processor face addressing lists
70         PtrList<labelIOList> faceProcAddressing_;
72         //- List of processor cell addressing lists
73         PtrList<labelIOList> cellProcAddressing_;
75         //- List of processor boundary addressing lists
76         PtrList<labelIOList> boundaryProcAddressing_;
79     // Private Member Functions
81         //- Read all meshes
82         void read();
84         //- Disallow default bitwise copy construct
85         processorMeshes(const processorMeshes&);
87         //- Disallow default bitwise assignment
88         void operator=(const processorMeshes&);
91 public:
93     // Constructors
95         //- Construct from components
96         processorMeshes(PtrList<Time>& databases, const word& meshName);
99     // Member Functions
101         //- Update the meshes based on the mesh files saved in
102         //  time directories
103         fvMesh::readUpdateState readUpdate();
105         //- Reconstruct point position after motion in parallel
106         void reconstructPoints(fvMesh& mesh);
108         PtrList<fvMesh>& meshes()
109         {
110             return meshes_;
111         }
112         const PtrList<labelIOList>& pointProcAddressing() const
113         {
114             return pointProcAddressing_;
115         }
116         PtrList<labelIOList>& faceProcAddressing()
117         {
118             return faceProcAddressing_;
119         }
120         const PtrList<labelIOList>& cellProcAddressing() const
121         {
122             return cellProcAddressing_;
123         }
124         const PtrList<labelIOList>& boundaryProcAddressing() const
125         {
126             return boundaryProcAddressing_;
127         }
133 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
135 } // End namespace Foam
137 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
139 #endif
141 // ************************************************************************* //