codedBase Class Referenceabstract

Base class for function objects and boundary conditions using dynamic code. More...

Inheritance diagram for codedBase:

Public Member Functions

 TypeName ("codedBase")
 Runtime type information. More...
 
 codedBase ()
 Construct null. More...
 
 codedBase (const word &name, const dictionary &dict)
 Construct from name and dictionary. More...
 
 codedBase (const dictionary &dict)
 Construct from dictionary. More...
 
 codedBase (const codedBase &cb)
 Copy constructor. More...
 
virtual ~codedBase ()
 Destructor. More...
 
void operator= (const codedBase &)=delete
 Disallow default bitwise assignment. More...
 
word codeTemplateC (const word &baseTypeName) const
 
word codeTemplateH (const word &baseTypeName) const
 
virtual void writeCode (Ostream &os) const
 

Protected Member Functions

void updateLibrary () const
 Update library as required. More...
 
virtual const word & codeName () const
 Name of the dynamically generated CodedType. More...
 
virtual string description () const
 Return a description (type + name) for the output. More...
 
virtual const dictionary & codeDict () const
 Get the dictionary to initialise the codeContext. More...
 
virtual wordList codeKeys () const =0
 Get the keywords associated with source code. More...
 
virtual void prepare (dynamicCode &, const dynamicCodeContext &) const =0
 Adapt the context for the current object. More...
 
virtual void clearRedirect () const =0
 Clear any redirected objects. More...
 

Detailed Description

Base class for function objects and boundary conditions using dynamic code.

Source files

Definition at line 53 of file codedBase.H.

Constructor & Destructor Documentation

◆ codedBase() [1/4]

codedBase ( )

Construct null.

Definition at line 364 of file codedBase.C.

◆ codedBase() [2/4]

codedBase ( const word &  name,
const dictionary &  dict 
)

Construct from name and dictionary.

Definition at line 368 of file codedBase.C.

◆ codedBase() [3/4]

codedBase ( const dictionary &  dict)

Construct from dictionary.

Definition at line 375 of file codedBase.C.

◆ codedBase() [4/4]

codedBase ( const codedBase &  cb)

Copy constructor.

Definition at line 382 of file codedBase.C.

◆ ~codedBase()

~codedBase ( )
virtual

Destructor.

Definition at line 391 of file codedBase.C.

Member Function Documentation

◆ updateLibrary()

◆ codeName()

const Foam::word & codeName ( ) const
protectedvirtual

Name of the dynamically generated CodedType.

Definition at line 350 of file codedBase.C.

Referenced by codedBase::writeCode().

Here is the caller graph for this function:

◆ description()

◆ codeDict()

const Foam::dictionary & codeDict ( ) const
protectedvirtual

Get the dictionary to initialise the codeContext.

Definition at line 356 of file codedBase.C.

Referenced by codedBase::writeCode().

Here is the caller graph for this function:

◆ codeKeys()

virtual wordList codeKeys ( ) const
protectedpure virtual

Get the keywords associated with source code.

Referenced by codedBase::writeCode().

Here is the caller graph for this function:

◆ prepare()

virtual void prepare ( dynamicCode &  ,
const dynamicCodeContext &   
) const
protectedpure virtual

Adapt the context for the current object.

◆ clearRedirect()

virtual void clearRedirect ( ) const
protectedpure virtual

Clear any redirected objects.

◆ TypeName()

TypeName ( "codedBase"  )

Runtime type information.

◆ operator=()

void operator= ( const codedBase &  )
delete

Disallow default bitwise assignment.

◆ codeTemplateC()

Foam::word codeTemplateC ( const word &  baseTypeName) const

Definition at line 397 of file codedBase.C.

◆ codeTemplateH()

Foam::word codeTemplateH ( const word &  baseTypeName) const

Definition at line 403 of file codedBase.C.

◆ writeCode()

void writeCode ( Ostream &  os) const
virtual

Definition at line 409 of file codedBase.C.

References List< T >::append(), codedBase::codeDict(), codedBase::codeKeys(), codedBase::codeName(), token::END_STATEMENT, forAll, found, Foam::nl, Ostream::write(), Foam::writeEntry(), and Foam::writeKeyword().

Referenced by Coded< Type >::write().

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

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