35 namespace functionObjects
37 namespace runTimeControls
52 stateFunctionObject& state
55 runTimeCondition(
name, obr,
dict, state),
56 valueAverageBase(
name, obr_,
dict, state, false),
57 nIterStartUp_(
dict.getOrDefault<label>(
"nIterStartUp", 10)),
77 bool running = iter_ > nIterStartUp_;
81 dictionary& conditionDict = this->conditionDict();
94 dictionary& conditionDict = this->conditionDict();
98 conditionDict.
set(
"iter", iter_);
virtual void writeState(dictionary &dict)
Write state to dictionary for restarts.
A list of keyword definitions, which are a keyword followed by a number of values (eg...
virtual bool calculate(dictionary &dict)
Calculate the averages.
virtual void reset()
Reset.
Macros for easy insertion into run-time selection tables.
virtual void write()
Write.
word name(const expressions::valueTypeCode typeCode)
A word representation of a valueTypeCode. Empty for expressions::valueTypeCode::INVALID.
virtual void readState(dictionary &dict)
Read state from dictionary.
A class for handling words, derived from Foam::string.
Base class for run time conditions.
Average run time condition - satisfied when average does not change by more than a given value...
defineTypeNameAndDebug(averageCondition, 0)
bool readIfPresent(const word &keyword, T &val, enum keyType::option matchOpt=keyType::REGEX) const
Find an entry if present, and assign to T val. FatalIOError if it is found and the number of tokens i...
Ostream & decrIndent(Ostream &os)
Decrement the indent level.
averageCondition(const word &name, const objectRegistry &obr, const dictionary &dict, stateFunctionObject &state)
Constructor.
addToRunTimeSelectionTable(runTimeCondition, averageCondition, dictionary)
messageStream Info
Information stream (stdout output on master, null elsewhere)
entry * set(entry *entryPtr)
Assign a new entry, overwriting any existing entry.
Registry of regIOobjects.
label iter_
Current iteration count.
Ostream & incrIndent(Ostream &os)
Increment the indent level.
virtual bool apply()
Apply the condition.
virtual void resetState(dictionary &dict)
Reset state.
const dictionary & conditionDict() const
Return const access to the conditions dictionary.