This class supports creating polyMeshes with baffles. More...
Classes | |
class | cellFaceIdentifier |
Identify cell faces in terms of cell Id and face Id. More... | |
Public Member Functions | |
meshReader (const fileName &, const scalar scaleFactor=1.0) | |
Construct from fileName. More... | |
meshReader (const meshReader &)=delete | |
Disallow default bitwise copy construction. More... | |
virtual | ~meshReader () |
Destructor. More... | |
virtual autoPtr< polyMesh > | mesh (const objectRegistry &) |
Create and return polyMesh. More... | |
void | writeAux (const objectRegistry &) const |
Write auxiliary information. More... | |
void | writeMesh (const polyMesh &, IOstream::streamFormat fmt=IOstream::BINARY) const |
Write mesh. More... | |
void | operator= (const meshReader &)=delete |
Disallow default bitwise assignment. More... | |
Static Public Member Functions | |
static void | warnDuplicates (const word &context, const wordList &) |
Warn about repeated names. More... | |
Protected Member Functions | |
virtual bool | readGeometry (const scalar scaleFactor=1.0)=0 |
Subclasses are required to supply this information. More... | |
Protected Attributes | |
fileName | geometryFile_ |
Referenced filename. More... | |
scalar | scaleFactor_ |
Geometry scaling. More... | |
pointField | points_ |
Points supporting the mesh. More... | |
labelList | origCellId_ |
Lookup original Cell number for a given cell. More... | |
List< List< cellFaceIdentifier > > | boundaryIds_ |
Identify boundary faces by cells and their faces. More... | |
wordList | patchTypes_ |
Boundary patch types. More... | |
wordList | patchNames_ |
Boundary patch names. More... | |
wordList | patchPhysicalTypes_ |
Boundary patch physical types. More... | |
faceListList | cellFaces_ |
List of faces for every cell. More... | |
faceList | baffleFaces_ |
List of each baffle face. More... | |
labelList | cellTableId_ |
Cell table id for each cell. More... | |
cellTable | cellTable_ |
Cell table persistent data saved as a dictionary. More... | |
Static Protected Attributes | |
static const cellModel * | unknownModel |
Pointers to cell shape models. More... | |
static const cellModel * | tetModel |
static const cellModel * | pyrModel |
static const cellModel * | prismModel |
static const cellModel * | hexModel |
This class supports creating polyMeshes with baffles.
The derived classes are responsible for providing the protected data. This implementation is somewhat messy, but could/should be restructured to provide a more generalised reader (at the moment it has been written for converting pro-STAR data).
The meshReader supports cellTable information (see new user's guide entry).
Definition at line 73 of file meshReader.H.
meshReader | ( | const fileName & | fileOrPrefix, |
const scalar | scaleFactor = 1.0 |
||
) |
Construct from fileName.
Definition at line 200 of file meshReader.C.
Referenced by meshReader::writeMesh().
|
delete |
Disallow default bitwise copy construction.
|
virtual |
Destructor.
Definition at line 230 of file meshReader.C.
References Foam::deleteDemandDrivenData().
|
protectedpure virtual |
Subclasses are required to supply this information.
Implemented in STARCD.
Referenced by meshReader::mesh().
Warn about repeated names.
Definition at line 34 of file meshReaderAux.C.
References IOobject::AUTO_WRITE, TimePaths::constant(), IOstream::currentVersion, HashTableCore::end(), Foam::endl(), HashTable< T, Key, Hash >::find(), forAll, forAllConstIter(), Foam::Info, HashTable< T, Key, Hash >::insert(), polyMesh::meshSubDir, IOobject::name(), Foam::nl, IOobject::NO_READ, IOobject::NO_WRITE, IOobject::note(), IOobject::objectPath(), List< T >::size(), objectRegistry::time(), IOstream::UNCOMPRESSED, IOobject::writeEndDivider(), IOobject::writeHeader(), and regIOobject::writeObject().
Referenced by meshReader::mesh().
|
virtual |
Create and return polyMesh.
Definition at line 121 of file meshReader.C.
References TimePaths::constant(), polyMesh::defaultRegion, Foam::endl(), Foam::Info, meshReader::points_, Foam::polyMeshUnMergeCyclics(), meshReader::readGeometry(), objectRegistry::time(), meshReader::warnDuplicates(), and meshReader::writeMesh().
void writeAux | ( | const objectRegistry & | registry | ) | const |
Write auxiliary information.
Definition at line 148 of file meshReaderAux.C.
References IOstream::ASCII, IOstream::BINARY, meshReader::cellTable_, meshReader::cellTableId_, meshReader::origCellId_, and cellTable::writeDict().
Referenced by meshReader::writeMesh().
void writeMesh | ( | const polyMesh & | mesh, |
IOstream::streamFormat | fmt = IOstream::BINARY |
||
) | const |
Write mesh.
Definition at line 167 of file meshReader.C.
References meshReader::baffleFaces_, meshReader::boundaryIds_, meshReader::cellFaces_, List< T >::clear(), IOstream::currentVersion, Foam::deleteDemandDrivenData(), Foam::endl(), Foam::Info, meshReader::meshReader(), polyMesh::removeFiles(), IOstream::UNCOMPRESSED, meshReader::writeAux(), and objectRegistry::writeObject().
Referenced by meshReader::mesh().
|
delete |
Disallow default bitwise assignment.
|
staticprotected |
Pointers to cell shape models.
Definition at line 237 of file meshReader.H.
Referenced by STARCD::readCells().
|
staticprotected |
Definition at line 238 of file meshReader.H.
Referenced by STARCD::readBoundary(), and STARCD::readCells().
|
staticprotected |
Definition at line 239 of file meshReader.H.
Referenced by STARCD::readBoundary(), and STARCD::readCells().
|
staticprotected |
Definition at line 240 of file meshReader.H.
Referenced by STARCD::readBoundary(), and STARCD::readCells().
|
staticprotected |
Definition at line 241 of file meshReader.H.
Referenced by STARCD::readBoundary(), and STARCD::readCells().
|
protected |
Referenced filename.
Definition at line 244 of file meshReader.H.
Referenced by STARCD::readGeometry().
|
protected |
Geometry scaling.
Definition at line 247 of file meshReader.H.
|
protected |
Points supporting the mesh.
Definition at line 250 of file meshReader.H.
Referenced by STARCD::cullPoints(), meshReader::mesh(), and STARCD::readPoints().
|
protected |
Lookup original Cell number for a given cell.
Definition at line 253 of file meshReader.H.
Referenced by STARCD::readCells(), and meshReader::writeAux().
|
protected |
Identify boundary faces by cells and their faces.
for each patch
Definition at line 257 of file meshReader.H.
Referenced by STARCD::readBoundary(), and meshReader::writeMesh().
|
protected |
Boundary patch types.
Definition at line 260 of file meshReader.H.
Referenced by STARCD::readBoundary().
|
protected |
Boundary patch names.
Definition at line 263 of file meshReader.H.
Referenced by STARCD::readBoundary().
|
protected |
Boundary patch physical types.
Definition at line 266 of file meshReader.H.
Referenced by STARCD::readBoundary().
|
protected |
List of faces for every cell.
Definition at line 269 of file meshReader.H.
Referenced by STARCD::cullPoints(), STARCD::readCells(), and meshReader::writeMesh().
|
protected |
List of each baffle face.
Definition at line 272 of file meshReader.H.
Referenced by STARCD::cullPoints(), STARCD::readCells(), and meshReader::writeMesh().
|
protected |
Cell table id for each cell.
Definition at line 275 of file meshReader.H.
Referenced by STARCD::readCells(), and meshReader::writeAux().
|
protected |
Cell table persistent data saved as a dictionary.
Definition at line 278 of file meshReader.H.
Referenced by STARCD::readAux(), STARCD::readCells(), and meshReader::writeAux().