functionObject Class Referenceabstract

Abstract base-class for Time/database functionObjects. More...

Inheritance diagram for functionObject:
Collaboration diagram for functionObject:

Public Member Functions

 ClassName ("functionObject")
 
virtual const wordtype () const =0
 Runtime type information. More...
 
 declareRunTimeSelectionTable (autoPtr, functionObject, dictionary,(const word &name, const Time &runTime, const dictionary &dict),(name, runTime, dict))
 
 functionObject (const word &name)
 Construct from components. More...
 
autoPtr< functionObjectclone () const
 Return clone. More...
 
 functionObject (const functionObject &)=delete
 Disallow default bitwise copy construction. More...
 
virtual ~functionObject ()
 Destructor. More...
 
const wordname () const
 Return the name of this functionObject. More...
 
virtual bool read (const dictionary &)
 Read and set the functionObject if its data have changed. More...
 
virtual bool executeAtStart () const
 Return true if the functionObject should be executed at the start. More...
 
virtual bool execute ()=0
 Called at each ++ or += of the time-loop. More...
 
virtual bool write ()=0
 Called at each ++ or += of the time-loop. More...
 
virtual bool end ()
 Called when Time::run() determines that the time-loop exits. More...
 
virtual scalar timeToNextWrite ()
 Called by Time::adjustTimeStep(). Allows the functionObject to. More...
 
virtual void updateMesh (const mapPolyMesh &mpm)
 Update for changes of mesh. More...
 
virtual void movePoints (const polyMesh &mesh)
 Update for changes of mesh. More...
 
void operator= (const functionObject &)=delete
 Disallow default bitwise assignment. More...
 

Static Public Member Functions

static autoPtr< functionObjectNew (const word &name, const Time &, const dictionary &)
 Select from dictionary, based on its "type" entry. More...
 

Public Attributes

Switch log
 Switch write log to Info. More...
 
Switch executeAtStart_
 Switch write log to Info. More...
 

Static Public Attributes

static bool postProcess
 Global post-processing mode switch. More...
 

Detailed Description

Abstract base-class for Time/database functionObjects.

See also
Foam::functionObjectList Foam::functionObjects::timeControl
Source files

Definition at line 229 of file functionObject.H.

Constructor & Destructor Documentation

◆ functionObject() [1/2]

functionObject ( const word name)

Construct from components.

Definition at line 44 of file functionObject.C.

References functionObject::New().

Referenced by functionObject::clone().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ functionObject() [2/2]

functionObject ( const functionObject )
delete

Disallow default bitwise copy construction.

◆ ~functionObject()

~functionObject ( )
virtual

Destructor.

Definition at line 115 of file functionObject.C.

Referenced by functionObject::clone().

Here is the caller graph for this function:

Member Function Documentation

◆ ClassName()

ClassName ( "functionObject"  )

◆ type()

virtual const word& type ( ) const
pure virtual

Runtime type information.

Referenced by probes::classifyFields().

Here is the caller graph for this function:

◆ declareRunTimeSelectionTable()

declareRunTimeSelectionTable ( autoPtr  ,
functionObject  ,
dictionary  ,
(const word &name, const Time &runTime, const dictionary &dict ,
(name, runTime, dict  
)

◆ clone()

◆ New()

Foam::autoPtr< Foam::functionObject > New ( const word name,
const Time runTime,
const dictionary dict 
)
static

Select from dictionary, based on its "type" entry.

Definition at line 55 of file functionObject.C.

References dict, Foam::endl(), Foam::exit(), Foam::FatalError, FatalErrorInFunction, dictionary::found(), Foam::Info, Foam::libs, dictionary::lookup(), functionObject::name(), Foam::nl, dlLibraryTable::open(), and runTime.

Referenced by functionObject::clone(), functionObject::functionObject(), functionObjectList::read(), and codedFunctionObject::~codedFunctionObject().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ name()

const Foam::word & name ( ) const

Return the name of this functionObject.

Definition at line 121 of file functionObject.C.

Referenced by functionObject::clone(), forces::file(), functionObject::New(), and surfaceFieldValue::outputDir().

Here is the caller graph for this function:

◆ read()

bool read ( const dictionary dict)
virtual

Read and set the functionObject if its data have changed.

Reimplemented in surfaceFieldValue, volFieldValue, forces, fieldAverage, pressure, streamlines, regionSizeDistribution, sampledSets, sampledSurfaces, sizeDistribution, turbulenceFields, comfort, probes, phaseScalarTransport, forceCoeffs, nearWallFields, fieldValueDelta, writeObjects, codedFunctionObject, age, wallHeatTransferCoeff, histogram, interfaceHeight, fieldValue, wallShearStress, fieldsExpression, systemCall, particles, fieldCoordinateSystemTransform, sixDoFRigidBodyControl, wallHeatFlux, surfaceInterpolate, timeControl, readFields, yPlus, stopAtFile, patchProbes, regionFunctionObject, log, phaseForces, sixDoFRigidBodyState, cloudInfo, stopAtClockTime, turbulenceIntensity, rigidBodyState, scalarTransport, writeVTK, removeRegisteredObject, timeActivatedFileUpdate, residuals, time, moleFractions< ThermoType >, stopAt, setWriteIntervalFunctionObject, processorField, writeDictionary, timeStep, CourantNo, specieReactionRates, setTimeStepFunctionObject, fieldExpression, blendingFactor, scale, uniform, randomise, shearStress, totalEnthalpy, Qdot, and dsmcFields.

Definition at line 127 of file functionObject.C.

References functionObject::executeAtStart_, functionObject::log, dictionary::lookupOrDefault(), and functionObject::postProcess.

Referenced by functionObject::clone(), timeStep::read(), time::read(), regionFunctionObject::read(), writeObjects::read(), functionObjectList::read(), and timeControl::timeControl().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ executeAtStart()

bool executeAtStart ( ) const
virtual

Return true if the functionObject should be executed at the start.

Reimplemented in fieldAverage, timeControl, and dsmcFields.

Definition at line 141 of file functionObject.C.

References functionObject::executeAtStart_.

Referenced by functionObject::clone().

Here is the caller graph for this function:

◆ execute()

◆ write()

◆ end()

bool end ( )
virtual

Called when Time::run() determines that the time-loop exits.

Reimplemented in sizeDistribution, codedFunctionObject, interfaceHeight, systemCall, stopAtFile, timeControl, and stopAt.

Definition at line 147 of file functionObject.C.

Referenced by functionObject::clone().

Here is the caller graph for this function:

◆ timeToNextWrite()

Foam::scalar timeToNextWrite ( )
virtual

Called by Time::adjustTimeStep(). Allows the functionObject to.

insert a write time earlier than that already in use by the run time. Returns the write time, or vGreat.

Reimplemented in timeControl.

Definition at line 153 of file functionObject.C.

Referenced by functionObject::clone().

Here is the caller graph for this function:

◆ updateMesh()

void updateMesh ( const mapPolyMesh mpm)
virtual

Update for changes of mesh.

Reimplemented in streamlines, sampledSets, sampledSurfaces, probes, and timeControl.

Definition at line 159 of file functionObject.C.

Referenced by functionObject::clone().

Here is the caller graph for this function:

◆ movePoints()

void movePoints ( const polyMesh mesh)
virtual

Update for changes of mesh.

Reimplemented in streamlines, sampledSets, sampledSurfaces, probes, and timeControl.

Definition at line 163 of file functionObject.C.

Referenced by functionObject::clone().

Here is the caller graph for this function:

◆ operator=()

void operator= ( const functionObject )
delete

Disallow default bitwise assignment.

Referenced by functionObject::clone().

Here is the caller graph for this function:

Member Data Documentation

◆ postProcess

bool postProcess
static

Global post-processing mode switch.

Definition at line 245 of file functionObject.H.

Referenced by functionObject::read().

◆ log

Switch log

Switch write log to Info.

Definition at line 248 of file functionObject.H.

Referenced by functionObject::read().

◆ executeAtStart_

Switch executeAtStart_

Switch write log to Info.

Definition at line 251 of file functionObject.H.

Referenced by functionObject::executeAtStart(), and functionObject::read().


The documentation for this class was generated from the following files: