functionObjects: Added fields() function to provide list of required fields to postProcess
With this change each functionObject provides the list of fields required so that the postProcess utility can pre-load them before executing the list of functionObjects. This provides a more convenient interface than using the -field or -fields command-line options to postProcess which are now redundant.
This commit is contained in:
@ -59,6 +59,7 @@ Foam::wordList Foam::codedFunctionObject::codeKeys() const
|
||||
"codeExecute",
|
||||
"codeInclude",
|
||||
"codeRead",
|
||||
"codeFields",
|
||||
"codeWrite",
|
||||
"localCode"
|
||||
};
|
||||
@ -152,6 +153,13 @@ Foam::functionObject& Foam::codedFunctionObject::redirectFunctionObject() const
|
||||
}
|
||||
|
||||
|
||||
Foam::wordList Foam::codedFunctionObject::fields() const
|
||||
{
|
||||
updateLibrary();
|
||||
return redirectFunctionObject().fields();
|
||||
}
|
||||
|
||||
|
||||
bool Foam::codedFunctionObject::execute()
|
||||
{
|
||||
updateLibrary();
|
||||
|
||||
Reference in New Issue
Block a user