92#ifndef Foam_functionObjects_codedFunctionObject_H
93#define Foam_functionObjects_codedFunctionObject_H
111 public functionObjects::timeFunctionObject,
136 virtual dlLibraryTable&
libs()
const;
151 virtual void prepare(dynamicCode&,
const dynamicCodeContext&)
const;
167 =
"functionObjectTemplate.C";
171 =
"functionObjectTemplate.H";
Class to control time during OpenFOAM simulations that is also the top-level objectRegistry.
Pointer management similar to std::unique_ptr, with some additional methods and type checking.
codedBase(const codedBase &)=delete
No copy construct.
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
A table of dynamically loaded libraries.
Encapsulation of dynamic code dictionaries.
Tools for handling dynamic code compilation.
const word & name() const noexcept
Return the name of this functionObject.
functionObject(const word &name, const bool withNamePrefix=defaultUseNamePrefix)
Construct from components.
Provides a general interface to enable dynamic code compilation.
virtual const dictionary & codeContext() const
Additional 'codeContext' dictionary to pass through.
virtual void prepare(dynamicCode &, const dynamicCodeContext &) const
Adapt the context for the current object.
autoPtr< functionObject > redirectFunctionObjectPtr_
Underlying functionObject.
functionObject & redirectFunctionObject() const
Dynamically compiled functionObject.
dictionary dict_
Input dictionary.
TypeName("coded")
Runtime type information.
void operator=(const codedFunctionObject &)=delete
No copy assignment.
virtual ~codedFunctionObject()=default
Destructor.
codedFunctionObject(const codedFunctionObject &)=delete
No copy construct.
static constexpr const char *const codeTemplateC
Name of the C code template to be used.
virtual const dictionary & codeDict() const
The code dictionary.
virtual void clearRedirect() const
Clear redirected object(s).
static constexpr const char *const codeTemplateH
Name of the H code template to be used.
virtual bool execute()
Called at each ++ or += of the time-loop.
virtual bool write()
Called at each ++ or += of the time-loop.
virtual dlLibraryTable & libs() const
Mutable access to the loaded dynamic libraries.
virtual bool end()
Called when Time::run() determines that the time-loop exits.
virtual bool read(const dictionary &)
Read and set the function object if its data have changed.
virtual string description() const
Description (type + name) for the output.
Virtual base class for function objects with a reference to Time.
A class for handling words, derived from Foam::string.
Function objects are OpenFOAM utilities to ease workflow configurations and enhance workflows.
#define TypeName(TypeNameString)
Declare a ClassName() with extra virtual type info.