functionObjects: Simplified the handling of the post-processing mode

Replaced the 'postProcess' argument to the 'write' and 'execute'
functions with the single static member 'postProcess' in the
functionObject base-class.
This commit is contained in:
Henry Weller
2016-06-13 08:36:03 +01:00
parent 41c2e4bc11
commit b3f4d5855d
102 changed files with 190 additions and 254 deletions

View File

@ -97,13 +97,13 @@ bool Foam::functionObjects::fieldValue::read(const dictionary& dict)
}
bool Foam::functionObjects::fieldValue::execute(const bool postProcess)
bool Foam::functionObjects::fieldValue::execute()
{
return true;
}
bool Foam::functionObjects::fieldValue::write(const bool postProcess)
bool Foam::functionObjects::fieldValue::write()
{
writeFiles::write();

View File

@ -172,10 +172,10 @@ public:
virtual bool read(const dictionary& dict);
//- Execute
virtual bool execute(const bool postProcess = false);
virtual bool execute();
//- Write to screen/file
virtual bool write(const bool postProcess = false);
virtual bool write();
};

View File

@ -164,10 +164,7 @@ bool Foam::functionObjects::fieldValues::fieldValueDelta::read
}
bool Foam::functionObjects::fieldValues::fieldValueDelta::write
(
const bool postProcess
)
bool Foam::functionObjects::fieldValues::fieldValueDelta::write()
{
writeFiles::write();
@ -206,10 +203,7 @@ bool Foam::functionObjects::fieldValues::fieldValueDelta::write
}
bool Foam::functionObjects::fieldValues::fieldValueDelta::execute
(
const bool postProcess
)
bool Foam::functionObjects::fieldValues::fieldValueDelta::execute()
{
return true;
}

View File

@ -171,10 +171,10 @@ public:
virtual bool read(const dictionary&);
//- Do nothing
virtual bool execute(const bool postProcess = false);
virtual bool execute();
//- Calculate and write
virtual bool write(const bool postProcess = false);
virtual bool write();
};

View File

@ -721,10 +721,7 @@ bool Foam::functionObjects::fieldValues::surfaceRegion::read
}
bool Foam::functionObjects::fieldValues::surfaceRegion::write
(
const bool postProcess
)
bool Foam::functionObjects::fieldValues::surfaceRegion::write()
{
fieldValue::write();

View File

@ -402,7 +402,7 @@ public:
virtual bool read(const dictionary&);
//- Calculate and write
virtual bool write(const bool postProcess = false);
virtual bool write();
};

View File

@ -275,10 +275,7 @@ bool Foam::functionObjects::fieldValues::volRegion::read
}
bool Foam::functionObjects::fieldValues::volRegion::write
(
const bool postProcess
)
bool Foam::functionObjects::fieldValues::volRegion::write()
{
fieldValue::write();

View File

@ -279,7 +279,7 @@ public:
virtual bool read(const dictionary&);
//- Calculate and write
virtual bool write(const bool postProcess = false);
virtual bool write();
};