40 #ifndef objectRegistryFunctionObject_functionObject_H
41 #define objectRegistryFunctionObject_functionObject_H
53 namespace functionObjects
76 template<
class ObjectType>
80 template<
class ObjectType>
90 template<
class ObjectType>
94 template<
class ObjectType>
98 template<
class ObjectType>
102 template<
class ObjectType>
105 const word& fieldName,
107 bool cacheable =
false
120 TypeName(
"objectRegistryFunctionObject");
A list of keywords followed by any number of values (e.g. words and numbers) or sub-dictionaries.
Abstract base-class for Time/database functionObjects.
const word & name() const
Return the name of this functionObject.
Specialisation of Foam::functionObject which holds a reference to an object registry....
const ObjectType & lookupObject(const word &fieldName) const
Lookup object from the objectRegistry.
objectRegistryFunctionObject(const word &name, const objectRegistry &obr, const dictionary &dict)
Construct from an objectRegistry and dictionary.
void operator=(const objectRegistryFunctionObject &)=delete
Disallow default bitwise assignment.
bool foundObject(const word &fieldName) const
Find field in the objectRegistry.
const objectRegistry & obr_
Reference to the objectRegistry.
virtual ~objectRegistryFunctionObject()
Destructor.
void cannotFindObjects(const wordList &fieldNames)
Prints a warning message that fieldNames cannot be found.
ObjectType & lookupObjectRef(const word &fieldName)
Lookup non-const object reference from the objectRegistry.
ObjectType & store(const tmp< ObjectType > &tfield)
Store the given field in the objectRegistry.
bool writeObject(const word &fieldName)
Write field if present in objectRegistry.
bool clearObject(const word &fieldName)
Clear field from the objectRegistry if present.
TypeName("objectRegistryFunctionObject")
Runtime type information.
void cannotFindObject(const word &fieldName)
Prints a warning message that fieldName cannot be found.
virtual bool read(const dictionary &)
Read optional controls.
Registry of regIOobjects.
A class for managing temporary objects.
A class for handling words, derived from string.
static List< word > fieldNames