69 tetBasePtIsPtr_->writeOpt(wOpt);
70 tetBasePtIsPtr_->instance() = inst;
80 fileName pointsInst(time().findInstance(meshDir(),
"points"));
81 fileName facesInst(time().findInstance(meshDir(),
"faces"));
86 Info<<
"Faces instance: old = " << facesInstance()
87 <<
" new = " << facesInst <<
nl 88 <<
"Points instance: old = " << pointsInstance()
89 <<
" new = " << pointsInst <<
endl;
92 if (facesInst != facesInstance())
104 setInstance(facesInst);
105 points_.instance() = pointsInst;
164 polyBoundaryMesh newBoundary
180 bool boundaryChanged =
false;
182 if (newBoundary.size() != boundary_.size())
184 boundaryChanged =
true;
188 wordList newTypes = newBoundary.types();
189 wordList newNames = newBoundary.names();
191 wordList oldTypes = boundary_.types();
192 wordList oldNames = boundary_.names();
198 oldTypes[patchi] != newTypes[patchi]
199 || oldNames[patchi] != newNames[patchi]
202 boundaryChanged =
true;
211 <<
"Number of patches has changed. This may have " 212 <<
"unexpected consequences. Proceed with care." <<
endl;
215 boundary_.setSize(newBoundary.size());
217 forAll(newBoundary, patchi)
219 boundary_.set(patchi, newBoundary[patchi].clone(boundary_));
226 boundary_[patchi] = polyPatch
228 newBoundary[patchi].
name(),
229 newBoundary[patchi].size(),
230 newBoundary[patchi].start(),
233 newBoundary[patchi].physicalType(),
234 newBoundary[patchi].inGroups()
243 if (owner_.hasHeaderClass())
273 boundary_.updateMesh();
276 boundary_.calcGeometry();
279 bounds_ = boundBox(points_);
299 label oldSize = pointZones_.size();
301 if (newPointZones.size() <= pointZones_.size())
303 pointZones_.setSize(newPointZones.size());
309 pointZones_[czI] = newPointZones[czI];
313 pointZones_.setSize(newPointZones.size());
315 for (label czI = oldSize; czI < newPointZones.size(); czI++)
317 pointZones_.set(czI, newPointZones[czI].clone(pointZones_));
336 oldSize = faceZones_.size();
338 if (newFaceZones.size() <= faceZones_.size())
340 faceZones_.setSize(newFaceZones.size());
346 faceZones_[fzI].resetAddressing
349 newFaceZones[fzI].flipMap()
354 faceZones_.setSize(newFaceZones.size());
356 for (label fzI = oldSize; fzI < newFaceZones.size(); fzI++)
358 faceZones_.set(fzI, newFaceZones[fzI].clone(faceZones_));
377 oldSize = cellZones_.size();
379 if (newCellZones.size() <= cellZones_.size())
381 cellZones_.setSize(newCellZones.size());
387 cellZones_[czI] = newCellZones[czI];
391 cellZones_.setSize(newCellZones.size());
393 for (label czI = oldSize; czI < newCellZones.size(); czI++)
395 cellZones_.set(czI, newCellZones[czI].clone(cellZones_));
399 tetBasePtIsPtr_ = readTetBasePtIs();
411 else if (pointsInst != pointsInstance())
434 autoPtr<labelIOList> newTetBasePtIsPtr = readTetBasePtIs();
437 updateGeomPoints(std::move(newPoints), newTetBasePtIsPtr);
writeOption
Enumeration defining write preferences.
ZoneMesh< faceZone, polyMesh > faceZoneMesh
A ZoneMesh with the type faceZone.
A class for handling file names.
vectorIOField pointIOField
pointIOField is a vectorIOField.
constexpr char nl
The newline '\n' character (0x0a)
Ostream & endl(Ostream &os)
Add newline and flush stream.
Ignore writing from objectRegistry::writeObject()
#define forAll(list, i)
Loop across all elements in list.
CompactIOList< face, label > faceCompactIOList
writeOption writeOpt() const noexcept
Get the write option.
word name(const expressions::valueTypeCode typeCode)
A word representation of a valueTypeCode. Empty for INVALID.
#define DebugInFunction
Report an information message using Foam::Info.
ZoneMesh< pointZone, polyMesh > pointZoneMesh
A ZoneMesh with the type pointZone.
int debug
Static debugging option.
CompactIOList< cell, label > cellCompactIOList
const fileName & instance() const noexcept
Read access to instance path component.
List< word > wordList
A List of words.
void setInstance(const fileName &instance, const IOobjectOption::writeOption wOpt=IOobject::AUTO_WRITE)
Set the instance for mesh files.
#define WarningInFunction
Report a warning using Foam::Warning.
messageStream Info
Information stream (stdout output on master, null elsewhere)
readUpdateState
Enumeration defining the state of the mesh after a read update.
virtual readUpdateState readUpdate()
Update the mesh based on the mesh files saved in.
ZoneMesh< cellZone, polyMesh > cellZoneMesh
A ZoneMesh with the type cellZone.
IOList< label > labelIOList
Label container classes.
static constexpr const zero Zero
Global zero (0)