32 void Foam::meshObjects::Delete(regIOobject& io)
34 if (meshObjects::debug)
39 if (io.ownedByRegistry())
46 <<
"Attempt to checkout and delete object " << io.name()
47 <<
" not owned by registry."
63 if (meshObjects::debug)
65 Pout<<
"meshObjects::movePoints(objectRegistry&) :"
66 <<
" moving " << Mesh::typeName
67 <<
" meshObjects for region " << obr.
name() <<
endl;
79 if (meshObjects::debug)
87 Delete<Mesh>(iter()->io_);
105 if (meshObjects::debug)
107 Pout<<
"meshObjects::distribute(objectRegistry&, "
108 "const polyDistributionMap& map) : updating "
110 <<
" meshObjects for region " << obr.
name() <<
endl;
122 if (meshObjects::debug)
131 Delete<Mesh>(iter()->io_);
149 if (meshObjects::debug)
151 Pout<<
"meshObjects::topoChange(objectRegistry&, "
152 "const polyTopoChangeMap& map) : updating " << Mesh::typeName
153 <<
" meshObjects for region " << obr.
name() <<
endl;
165 if (meshObjects::debug)
174 Delete<Mesh>(iter()->io_);
192 if (meshObjects::debug)
194 Pout<<
"meshObjects::mapMesh(objectRegistry&, "
195 "const polyMeshMap& map) : updating " << Mesh::typeName
196 <<
" meshObjects for region " << obr.
name() <<
endl;
208 if (meshObjects::debug)
216 Delete<Mesh>(iter()->io_);
230 if (meshObjects::debug)
232 Pout<<
"meshObjects::addPatch(objectRegistry&, "
233 "const label patchi) : updating " << Mesh::typeName
234 <<
" meshObjects for region " << obr.
name() <<
endl;
246 if (meshObjects::debug)
248 Pout<<
" Adding patch to " << iter()->io_.
name() <<
endl;
255 Delete<Mesh>(iter()->io_);
266 const bool validBoundary
274 if (meshObjects::debug)
276 Pout<<
"meshObjects::addPatch(objectRegistry&, "
277 "const labelUList&, const bool) : updating " << Mesh::typeName
278 <<
" meshObjects for region " << obr.
name() <<
endl;
290 if (meshObjects::debug)
292 Pout<<
" Adding patch to " << iter()->io_.
name() <<
endl;
302 Delete<Mesh>(iter()->io_);
308 template<
class Mesh,
template<
class>
class MeshObjectType>
316 if (meshObjects::debug)
318 Pout<<
"meshObjects::clear(objectRegistry&) :"
319 <<
" clearing " << Mesh::typeName
320 <<
" meshObjects for region " << obr.
name() <<
endl;
325 Delete<Mesh>(iter()->io_);
333 template<
class>
class FromType,
334 template<
class>
class ToType
343 if (meshObjects::debug)
345 Pout<<
"meshObjects::clearUpto(objectRegistry&) :"
346 <<
" clearing " << Mesh::typeName
347 <<
" meshObjects for region " << obr.
name() <<
endl;
352 if (!
isA<ToType<Mesh>>(*iter()))
354 Delete<Mesh>(iter()->io_);
#define forAllIter(Container, container, iter)
Iterate across all elements in the container object of type.
An STL-conforming hash table.
const word & name() const
Return name.
virtual const fileName & name() const
Return the name of the stream.
Templated abstract base-class for optional mesh objects used to automate their allocation to the mesh...
static void clearUpto(objectRegistry &)
Clear all meshObjects derived from FromType up to (but not including)
static void movePoints(objectRegistry &)
static void mapMesh(objectRegistry &, const polyMeshMap &)
static void clear(objectRegistry &)
static void distribute(objectRegistry &, const polyDistributionMap &)
static void addPatch(objectRegistry &, const label patchi)
static void topoChange(objectRegistry &, const polyTopoChangeMap &)
static void reorderPatches(objectRegistry &, const labelUList &newToOld, const bool validBoundary)
Registry of regIOobjects.
HashTable< const Type * > lookupClass(const bool strict=false) const
Lookup and return all objects of the given Type.
Class containing mesh-to-mesh mapping information after a mesh distribution where we send parts of me...
Class containing mesh-to-mesh mapping information.
Class containing mesh-to-mesh mapping information after a change in polyMesh topology.
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
Ostream & endl(Ostream &os)
Add newline and flush stream.
errorManip< error > abort(error &err)
bool isA(const Type &t)
Check if a dynamic_cast to typeid is possible.
prefixOSstream Pout(cout, "Pout")