mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
functionObjects: Removed redundant "start()" member function
This commit is contained in:
@ -128,13 +128,6 @@ Foam::OutputFilterFunctionObject<OutputFilter>::OutputFilterFunctionObject
|
|||||||
),
|
),
|
||||||
outputControl_(t, dict, "output"),
|
outputControl_(t, dict, "output"),
|
||||||
evaluateControl_(t, dict, "evaluate")
|
evaluateControl_(t, dict, "evaluate")
|
||||||
{}
|
|
||||||
|
|
||||||
|
|
||||||
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
|
|
||||||
|
|
||||||
template<class OutputFilter>
|
|
||||||
bool Foam::OutputFilterFunctionObject<OutputFilter>::start()
|
|
||||||
{
|
{
|
||||||
readDict();
|
readDict();
|
||||||
if (!allocateFilter())
|
if (!allocateFilter())
|
||||||
@ -143,11 +136,11 @@ bool Foam::OutputFilterFunctionObject<OutputFilter>::start()
|
|||||||
<< "Cannot construct " << OutputFilter::typeName
|
<< "Cannot construct " << OutputFilter::typeName
|
||||||
<< exit(FatalError);
|
<< exit(FatalError);
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
|
||||||
|
|
||||||
template<class OutputFilter>
|
template<class OutputFilter>
|
||||||
bool Foam::OutputFilterFunctionObject<OutputFilter>::execute
|
bool Foam::OutputFilterFunctionObject<OutputFilter>::execute
|
||||||
(
|
(
|
||||||
@ -252,10 +245,11 @@ bool Foam::OutputFilterFunctionObject<OutputFilter>::read
|
|||||||
if (dict != dict_)
|
if (dict != dict_)
|
||||||
{
|
{
|
||||||
dict_ = dict;
|
dict_ = dict;
|
||||||
outputControl_.read(dict);
|
|
||||||
|
|
||||||
// Reset the OutputFilter
|
outputControl_.read(dict);
|
||||||
return start();
|
readDict();
|
||||||
|
|
||||||
|
return true;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|||||||
@ -158,9 +158,6 @@ public:
|
|||||||
|
|
||||||
// Function object control
|
// Function object control
|
||||||
|
|
||||||
//- Called at the start of the time-loop
|
|
||||||
virtual bool start();
|
|
||||||
|
|
||||||
//- Called at each ++ or += of the time-loop. forceWrite overrides
|
//- Called at each ++ or += of the time-loop. forceWrite overrides
|
||||||
// the usual outputControl behaviour and forces writing always
|
// the usual outputControl behaviour and forces writing always
|
||||||
// (used in post-processing mode)
|
// (used in post-processing mode)
|
||||||
|
|||||||
@ -183,9 +183,6 @@ public:
|
|||||||
//- Name
|
//- Name
|
||||||
virtual const word& name() const;
|
virtual const word& name() const;
|
||||||
|
|
||||||
//- Called at the start of the time-loop
|
|
||||||
virtual bool start() = 0;
|
|
||||||
|
|
||||||
//- Called at each ++ or += of the time-loop. forceWrite overrides
|
//- Called at each ++ or += of the time-loop. forceWrite overrides
|
||||||
// the usual outputControl behaviour and forces writing always
|
// the usual outputControl behaviour and forces writing always
|
||||||
// (used in post-processing mode)
|
// (used in post-processing mode)
|
||||||
|
|||||||
@ -136,6 +136,9 @@ Foam::codedFunctionObject::codedFunctionObject
|
|||||||
{
|
{
|
||||||
read(dict_);
|
read(dict_);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
updateLibrary(redirectType_);
|
||||||
|
redirectFunctionObject();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -147,8 +150,7 @@ Foam::codedFunctionObject::~codedFunctionObject()
|
|||||||
|
|
||||||
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
|
||||||
|
|
||||||
Foam::functionObject&
|
Foam::functionObject& Foam::codedFunctionObject::redirectFunctionObject() const
|
||||||
Foam::codedFunctionObject::redirectFunctionObject() const
|
|
||||||
{
|
{
|
||||||
if (!redirectFunctionObjectPtr_.valid())
|
if (!redirectFunctionObjectPtr_.valid())
|
||||||
{
|
{
|
||||||
@ -166,13 +168,6 @@ Foam::codedFunctionObject::redirectFunctionObject() const
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
bool Foam::codedFunctionObject::start()
|
|
||||||
{
|
|
||||||
updateLibrary(redirectType_);
|
|
||||||
return redirectFunctionObject().start();
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
bool Foam::codedFunctionObject::execute(const bool forceWrite)
|
bool Foam::codedFunctionObject::execute(const bool forceWrite)
|
||||||
{
|
{
|
||||||
updateLibrary(redirectType_);
|
updateLibrary(redirectType_);
|
||||||
|
|||||||
@ -171,9 +171,6 @@ public:
|
|||||||
//- Dynamically compiled functionObject
|
//- Dynamically compiled functionObject
|
||||||
functionObject& redirectFunctionObject() const;
|
functionObject& redirectFunctionObject() const;
|
||||||
|
|
||||||
//- Called at the start of the time-loop
|
|
||||||
virtual bool start();
|
|
||||||
|
|
||||||
//- Called at each ++ or += of the time-loop. forceWrite overrides the
|
//- Called at each ++ or += of the time-loop. forceWrite overrides the
|
||||||
// outputControl behaviour.
|
// outputControl behaviour.
|
||||||
virtual bool execute(const bool forceWrite);
|
virtual bool execute(const bool forceWrite);
|
||||||
|
|||||||
@ -75,12 +75,6 @@ Foam::functionObjects::setTimeStepFunctionObject::time() const
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
bool Foam::functionObjects::setTimeStepFunctionObject::start()
|
|
||||||
{
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
bool Foam::functionObjects::setTimeStepFunctionObject::execute
|
bool Foam::functionObjects::setTimeStepFunctionObject::execute
|
||||||
(
|
(
|
||||||
const bool forceWrite
|
const bool forceWrite
|
||||||
|
|||||||
@ -109,9 +109,6 @@ public:
|
|||||||
|
|
||||||
// Function object control
|
// Function object control
|
||||||
|
|
||||||
//- Called at the start of the time-loop
|
|
||||||
virtual bool start();
|
|
||||||
|
|
||||||
//- Called at each ++ or += of the time-loop
|
//- Called at each ++ or += of the time-loop
|
||||||
virtual bool execute(const bool forceWrite);
|
virtual bool execute(const bool forceWrite);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user