FreeFOAM The Cross-Platform CFD Toolkit
ensightPartCells.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 | Copyright (C) 1991-2010 OpenCFD Ltd.
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::ensightPartCells
26 
27 Description
28  An implementation of ensightPart to hold volume mesh cells.
29 
30 SourceFiles
31  ensightPartCells.C
32 
33 \*---------------------------------------------------------------------------*/
34 
35 #ifndef ensightPartCells_H
36 #define ensightPartCells_H
37 
38 #include "ensightPart.H"
39 #include <OpenFOAM/typeInfo.H>
40 
41 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
42 
43 namespace Foam
44 {
45 
46 /*---------------------------------------------------------------------------*\
47  Class ensightPartCells Declaration
48 \*---------------------------------------------------------------------------*/
49 
51 :
52  public ensightPart
53 {
54  // Private Member Functions
55 
56  //- Disallow default bitwise assignment
57  void operator=(const ensightPartCells&);
58 
59  //- classify the cell types
60  void classify(const labelList& idLabels = labelList::null());
61 
62  //- track points used
63  virtual localPoints calcLocalPoints() const;
64 
65  //- track the points used
66  // virtual void makeLocalPointMap();
67 
68  //- element connectivity
69  virtual void writeConnectivity
70  (
71  ensightGeoFile& os,
72  const string& key,
73  const labelList& idList,
74  const labelList& pointMap
75  ) const;
76 
77 
78 protected:
79 
80  //- addressable Ensight element types
81  enum elemType
82  {
88  };
89 
90  // Static data members
92 
93 
94 public:
95 
96  //- Runtime type information
97  TypeName("ensightCells");
98 
99  // Constructors
100 
101  //- Construct empty part with number and description
102  ensightPartCells(label partNumber, const string& partDescription);
103 
104  //- Construct from polyMesh without zones
105  ensightPartCells(label partNumber, const polyMesh&);
106 
107  //- Construct from polyMesh and list of (non-zoned) cells
109  (
110  label partNumber,
111  const polyMesh&,
112  const labelList&
113  );
114 
115  //- Construct from polyMesh and cellZone
117  (
118  label partNumber,
119  const polyMesh&,
120  const cellZone&
121  );
122 
123  //- Construct as copy
125 
126  //- Construct from Istream
128 
129  //- Construct on freestore from Istream
131  {
133  }
134 
135 
136  //- Destructor
137  virtual ~ensightPartCells();
138 
139 
140  // Member Functions
141 
142  //- static listing of the element types
143  virtual List<word> const& elementTypes() const
144  {
145  return elemTypes_;
146  }
147 };
148 
149 
150 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
151 
152 } // End namespace Foam
153 
154 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
155 
156 #endif
157 
158 // ************************ vim: set sw=4 sts=4 et: ************************ //