MultiRegionRefs, MultiRegionUList, MultiRegionList: Centralised region prefixing

These classes permit any PtrList of region-associated objects (meshes,
solvers, domainDecompositions, ...) to prefix the region name to the log.

At present these classes are used by decomposePar and reconstructPar
only. The foamMultiRun solver still handles its own prefixing.
This commit is contained in:
Will Bainbridge
2023-11-23 10:21:22 +00:00
parent 14abee15e0
commit 77eec2cda3
14 changed files with 607 additions and 449 deletions

View File

@ -322,7 +322,7 @@ int main(int argc, char *argv[])
{
forAll(regionNames, regioni)
{
writeDecomposition(regionMeshes.meshes(regioni)());
writeDecomposition(regionMeshes[regioni]());
Info<< endl;
fileHandler().flush();
}
@ -351,7 +351,7 @@ int main(int argc, char *argv[])
{
if (writeCellProc && stat >= fvMesh::TOPO_CHANGE)
{
writeDecomposition(regionMeshes.meshes(regioni)());
writeDecomposition(regionMeshes[regioni]());
Info<< endl;
fileHandler().flush();
}
@ -368,8 +368,8 @@ int main(int argc, char *argv[])
// Prefixed scope
{
const RegionConstRef<domainDecomposition> meshes =
regionMeshes.meshes(regioni);
const RegionRef<domainDecomposition> meshes =
regionMeshes[regioni];
// Search for objects at this time
IOobjectList objects
@ -586,8 +586,8 @@ int main(int argc, char *argv[])
{
// Prefixed scope
{
const RegionConstRef<domainDecomposition> meshes =
regionMeshes.meshes(regioni);
const RegionRef<domainDecomposition> meshes =
regionMeshes[regioni];
Info<< "Collecting uniform files" << endl;