functionObjects: Standardised file paths for functions applied to regions

Function objects now write to the following path when applied to a
non-default region of a multi-region case:

    postProcessing/<regionName>/<functionName>/<time>/

Previously the order of <regionName> and <functionName> was not
consistent between the various function objects.

Resolves bug report https://bugs.openfoam.org/view.php?id=3907
This commit is contained in:
Will Bainbridge
2022-10-13 11:19:27 +01:00
parent 2fc1f0b138
commit 5b11f5a833
7 changed files with 49 additions and 55 deletions

View File

@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration | Website: https://openfoam.org
\\ / A nd | Copyright (C) 2015-2021 OpenFOAM Foundation
\\ / A nd | Copyright (C) 2015-2022 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@ -364,11 +364,10 @@ void Foam::mergeAndWrite
fileName outputDir
(
set.time().path()
/ (Pstream::parRun() ? ".." : "")
/ "postProcessing"
/ mesh.pointsInstance()
/ set.name()
set.time().globalPath()
/functionObjects::writeFile::outputPrefix
/mesh.pointsInstance()
/set.name()
);
outputDir.clean();