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:
Henry Weller
2021-10-21 09:23:34 +01:00
parent 777e5aeece
commit c01118589f
110 changed files with 809 additions and 746 deletions

View File

@ -77,6 +77,12 @@ bool Foam::functionObjects::FUNCTIONOBJECT::read(const dictionary& dict)
}
Foam::wordList Foam::functionObjects::FUNCTIONOBJECT::fields() const
{
return wordList::null();
}
bool Foam::functionObjects::FUNCTIONOBJECT::execute()
{
return true;

View File

@ -118,6 +118,9 @@ public:
//- Read the FUNCTIONOBJECT data
virtual bool read(const dictionary&);
//- Return the list of fields required
virtual wordList fields() const;
//- Execute, currently does nothing
virtual bool execute();