Helper for controlDict with functions
It would be better and very easy to use a FileHelper
for the controlDict
file.
We should have a good API to use functions:
https://www.openfoam.com/documentation/guides/v2112/doc/guide-function-objects.html
We have in our solvers:
code_control_dict_functions = dedent(
"""
functions
{
minmaxdomain
{
type fieldMinMax;
//type banana;
libs ("libfieldFunctionObjects.so");
enabled true;
mode component;
writeControl timeStep;
writeInterval 1;
log true;
fields (p U);
}
};
"""
)
and
code_control_dict_functions = dedent(
"""
functions
{
#includeFunc solverInfo
#includeFunc streamlines
}
"""
)
Edited by Pierre Augier