42 Foam::word Foam::surfMesh::meshSubDir =
"surfMesh";
87 shallowCopy(this->storedFaces());
93 this->updatePointsRef();
94 this->updateFacesRef();
108 time().findInstance(meshDir(),
"points"),
117 time().findInstance(meshDir(),
"faces"),
126 time().findInstance(meshDir(),
"surfZones"),
137 Foam::surfMesh::surfMesh
183 Foam::surfMesh::surfMesh
229 <<
" name: " << io.
name()
231 <<
" local: " << io.
local()
359 if (zones.
size() <= 1)
368 zones[zoneI].start() = count;
369 count += zones[zoneI].
size();
375 <<
"more faces " <<
nFaces() <<
" than zones " << count
376 <<
" ... extending final zone" 381 else if (count >
size())
384 <<
"more zones " << count <<
" than faces " <<
nFaces()
402 zones[zoneI] =
surfZone(srfZones[zoneI], zoneI);
417 rm(meshFilesPath/
"points");
418 rm(meshFilesPath/
"faces");
419 rm(meshFilesPath/
"surfZones");
virtual void updateRefs()
Update references to storedPoints/storedFaces.
A simple container for copying or transferring objects of type <T>.
const fileName & facesInstance() const
Return the current instance directory for faces.
#define forAll(list, i)
Loop across all elements in list.
virtual label size() const
Return number of faces.
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
const word & name() const
Return name.
faceCompactIOList & storedIOFaces()
Non-const access to the faces.
A class for handling file names.
errorManipArg< error, int > exit(error &err, const int errNo=1)
virtual void updatePointsRef()
Update references to storedPoints.
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
surfZoneList & storedZones()
Non-const access to the zones.
const fileName & pointsInstance() const
Return the current instance directory for points.
A surface zone on a MeshedSurface.
void size(const label)
Override size to be inconsistent with allocated storage.
faceList & storedFaces()
Non-const access to the faces.
Ostream & endl(Ostream &os)
Add newline and flush stream.
void addZones(const List< surfZone > &, const bool validate=true)
Add surface zones.
pointIOField & storedIOPoints()
Non-const access to the points.
surfZoneList & storedZones()
Non-const access to the zones.
static void write(const fileName &, const surfMesh &)
Write to file.
fileName path() const
Return complete path.
Wraps the normal objectRegistry with a local instance for surfaces.
Functions used by OpenFOAM that are specific to POSIX compliant operating systems and need to be repl...
vectorField pointField
pointField is a vectorField.
Xfer< MeshedSurface< face > > xfer()
Transfer contents to the Xfer container as a MeshedSurface.
List< Face > & storedFaces()
Non-const access to the faces.
static word meshSubDir
Return the mesh sub-directory name (normally "surfMesh")
A class for handling words, derived from string.
virtual const faceList & faces() const
Return faces.
const fileName & local() const
pointField & storedPoints()
Non-const access to global points.
virtual void updateFacesRef()
Update references to storedFaces.
surfZoneIOList & storedIOZones()
Non-const access to the zones.
void removeZones()
Update the mesh corresponding to given map.
virtual label nPoints() const
Return the number of raw points.
A helper class for storing points, faces and zones with IO capabilities.
A surface mesh consisting of general polygon faces.
defineTypeNameAndDebug(combustionModel, 0)
A proxy for writing MeshedSurface, UnsortedMeshedSurface and surfMesh to various file formats...
void removeFiles() const
Remove all files from mesh instance()
word name(const complex &)
Return a string representation of a complex.
List< surfZone > surfZoneList
bool notNull(const T &t)
Return true if t is not a reference to the nullObject of type T.
Template functions to aid in the implementation of demand driven data.
const fileName & instance() const
void transfer(MeshedSurface< face > &)
Transfer the contents of the argument and annul the argument.
#define WarningInFunction
Report a warning using Foam::Warning.
virtual const surfZoneList & surfZones() const
Return surface zones.
void reset(const Xfer< pointField > &points, const Xfer< faceList > &faces, const Xfer< surfZoneList > &zones)
Reset primitive data (points, faces and zones)
pointField & storedPoints()
Non-const access to global points.
virtual const fileName & dbDir() const
Local directory path of this objectRegistry relative to the time.
virtual label nFaces() const
Return the number of raw faces.
void checkZones()
Check the surface zone definitions.
virtual const pointField & points() const
Return points.
void resetPrimitives(const Xfer< pointField > &points, const Xfer< faceList > &faces, const Xfer< surfZoneList > &zones, const bool validate=true)
Reset mesh primitive data.
virtual ~surfMesh()
Destructor.
bool rm(const fileName &)
Remove a file, returning true if successful otherwise false.
T & last()
Return the last element of the list.
const objectRegistry & db() const
Return the local objectRegistry.
fileName meshDir() const
Return the local mesh directory (dbDir()/meshSubDir)
IOobject defines the attributes of an object for which implicit objectRegistry management is supporte...
void transfer(List< T > &)
Transfer the contents of the argument List into this list.