mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
BUG: codedFunctionObject: add timeSet functionality
This commit is contained in:
@ -31,6 +31,39 @@ Description
|
||||
This function object provides a general interface to enable dynamic code
|
||||
compilation.
|
||||
|
||||
The entries are
|
||||
code : c++; upon functionObject::write()
|
||||
codeInclude : include files
|
||||
codeOptions : include paths; inserted into EXE_INC in Make/options
|
||||
codeLibs : link line; inserted into LIB_LIBS in Make/options
|
||||
|
||||
codeExecute : c++;upon functionObject::execute();
|
||||
codeRead : c++; upon functionObject::read();
|
||||
codeEnd : c++; upon functionObject::end();
|
||||
codeData : c++; local member data (null constructed);
|
||||
codeTimeSet : c++; upon functionObject::timeSet();
|
||||
localCode : c++; local static functions
|
||||
|
||||
Example of function object specification:
|
||||
\verbatim
|
||||
difference
|
||||
{
|
||||
functionObjectLibs ("libutilityFunctionObjects.so");
|
||||
|
||||
type coded;
|
||||
// Name of on-the-fly generated functionObject
|
||||
redirectType writeMagU;
|
||||
code
|
||||
#{
|
||||
// Lookup U
|
||||
const volVectorField& U = mesh().lookupObject<volVectorField>("U");
|
||||
// Write
|
||||
mag(U).write();
|
||||
}
|
||||
}
|
||||
\endverbatim
|
||||
|
||||
|
||||
SeeAlso
|
||||
Foam::functionObject
|
||||
Foam::OutputFilterFunctionObject
|
||||
@ -77,6 +110,7 @@ protected:
|
||||
string codeRead_;
|
||||
string codeExecute_;
|
||||
string codeEnd_;
|
||||
string codeTimeSet_;
|
||||
|
||||
//- Underlying functionObject
|
||||
mutable autoPtr<functionObject> redirectFunctionObjectPtr_;
|
||||
|
||||
Reference in New Issue
Block a user