35 const word& objectName,
36 const word& entryName,
37 const Type& defaultValue
40 Type result = defaultValue;
49 const word& objectName,
50 const word& entryName,
54 if (this->
found(objectName))
56 const dictionary& baseDict = this->subDict(objectName);
67 const word& objectName,
68 const word& entryName,
72 if (!this->
found(objectName))
77 dictionary& baseDict = this->subDict(objectName);
78 baseDict.
add(entryName, value,
true);
85 const word& objectName,
86 const word& entryName,
90 if (!this->
found(resultsName_))
95 dictionary& resultsDict = this->subDict(resultsName_);
97 if (!resultsDict.
found(objectName))
106 if (!objectDict.
found(dictTypeName))
113 resultTypeDict.
add(entryName, value,
true);
120 const word& objectName,
121 const word& entryName,
122 const Type& defaultValue
125 Type result = defaultValue;
126 (void)getObjectResult(objectName, entryName, result);
134 const word& objectName,
135 const word& entryName,
139 if (this->
found(resultsName_))
141 const dictionary& resultsDict = this->subDict(resultsName_);
143 if (resultsDict.
found(objectName))
149 if (objectDict.
found(dictTypeName))
152 objectDict.
subDict(dictTypeName);
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
const dictionary & subDict(const word &keyword, enum keyType::option matchOpt=keyType::REGEX) const
Find and return a sub-dictionary.
bool found(const word &keyword, enum keyType::option matchOpt=keyType::REGEX) const
Search for an entry (const access) with the given keyword.
bool readIfPresent(const word &keyword, T &val, enum keyType::option matchOpt=keyType::REGEX) const
entry * add(entry *entryPtr, bool mergeEntry=false)
Add a new entry.
Sums a given list of (at least two or more) fields and outputs the result into a new field,...
void setObjectResult(const word &objectName, const word &entryName, const Type &value)
Add result from named object.
Type getObjectProperty(const word &objectName, const word &entryName, const Type &defaultValue=Type(Zero)) const
Retrieve generic property from named object.
void setObjectProperty(const word &objectName, const word &entryName, const Type &value)
Add generic property from named object.
Type getObjectResult(const word &objectName, const word &entryName, const Type &defaultValue=Type(Zero)) const
Retrieve result from named object.
A traits class, which is primarily used for primitives.
A class for handling words, derived from Foam::string.