Base class for run time conditions. More...
Public Member Functions | |
| TypeName ("runTimeCondition") | |
| Runtime type information. More... | |
| declareRunTimeSelectionTable (autoPtr, runTimeCondition, dictionary,(const word &name, const objectRegistry &obr, const dictionary &dict, stateFunctionObject &state),(name, obr, dict, state)) | |
| Declare runtime constructor selection table. More... | |
| runTimeCondition (const word &name, const objectRegistry &obr, const dictionary &dict, stateFunctionObject &state) | |
| Constructor. More... | |
| virtual | ~runTimeCondition ()=default |
| Destructor. More... | |
| virtual const word & | name () const |
| Return the condition name. More... | |
| virtual bool | active () const |
| Return the active flag. More... | |
| virtual label | groupID () const |
| Return the group index. More... | |
| virtual bool | apply ()=0 |
| Apply the condition. More... | |
| virtual void | write ()=0 |
| Write. More... | |
Static Public Member Functions | |
| static autoPtr< runTimeCondition > | New (const word &conditionName, const objectRegistry &obr, const dictionary &dict, stateFunctionObject &state) |
| Selector. More... | |
Public Attributes | |
| Switch | log |
| Switch to send output to Info. More... | |
Protected Member Functions | |
| dictionary & | setConditionDict () |
| Set the condition dictionary (create if necessary) More... | |
| const dictionary & | conditionDict () const |
| Return const access to the conditions dictionary. More... | |
| dictionary & | conditionDict () |
| Return non-const access to the conditions dictionary. More... | |
Protected Attributes | |
| word | name_ |
| Condition name. More... | |
| const objectRegistry & | obr_ |
| Reference to the object registry. More... | |
| stateFunctionObject & | state_ |
| State. More... | |
| bool | active_ |
| On/off switch. More... | |
| dictionary & | conditionDict_ |
| Reference to the condition dictionary. More... | |
| label | groupID_ |
| Group index - if applied, all conditions in a group must be. More... | |
Base class for run time conditions.
Definition at line 61 of file runTimeCondition.H.
| runTimeCondition | ( | const word & | name, |
| const objectRegistry & | obr, | ||
| const dictionary & | dict, | ||
| stateFunctionObject & | state | ||
| ) |
Constructor.
Definition at line 78 of file runTimeCondition.C.
|
virtualdefault |
Destructor.
|
protected |
Set the condition dictionary (create if necessary)
Definition at line 48 of file runTimeCondition.C.
References dictionary::add(), dictionary::found(), runTimeCondition::name_, stateFunctionObject::propertyDict(), runTimeCondition::state_, and dictionary::subDict().
|
protected |
Return const access to the conditions dictionary.
Definition at line 62 of file runTimeCondition.C.
|
protected |
Return non-const access to the conditions dictionary.
Definition at line 69 of file runTimeCondition.C.
| TypeName | ( | "runTimeCondition" | ) |
Runtime type information.
| declareRunTimeSelectionTable | ( | autoPtr | , |
| runTimeCondition | , | ||
| dictionary | , | ||
| (const word &name, const objectRegistry &obr, const dictionary &dict, stateFunctionObject &state) | , | ||
| (name, obr, dict, state) | |||
| ) |
Declare runtime constructor selection table.
|
static |
Selector.
Definition at line 35 of file runTimeConditionNew.C.
References dict, Foam::endl(), Foam::exit(), Foam::FatalIOError, FatalIOErrorInLookup, and Foam::Info.
|
virtual |
Return the condition name.
Definition at line 98 of file runTimeCondition.C.
|
virtual |
Return the active flag.
Definition at line 104 of file runTimeCondition.C.
Referenced by runTimeControl::execute().
|
virtual |
Return the group index.
Definition at line 111 of file runTimeCondition.C.
Referenced by runTimeControl::execute().
|
pure virtual |
Apply the condition.
Implemented in averageCondition, equationInitialResidualCondition, minMaxCondition, maxDurationCondition, equationMaxIterCondition, and minTimeStepCondition.
Referenced by runTimeControl::execute().
|
pure virtual |
Write.
Implemented in averageCondition, equationInitialResidualCondition, minMaxCondition, maxDurationCondition, equationMaxIterCondition, and minTimeStepCondition.
|
protected |
Condition name.
Definition at line 69 of file runTimeCondition.H.
Referenced by equationMaxIterCondition::apply(), maxDurationCondition::apply(), averageCondition::apply(), and runTimeCondition::setConditionDict().
|
protected |
Reference to the object registry.
Definition at line 72 of file runTimeCondition.H.
Referenced by minTimeStepCondition::apply(), equationMaxIterCondition::apply(), maxDurationCondition::apply(), and averageCondition::apply().
|
protected |
State.
Definition at line 75 of file runTimeCondition.H.
Referenced by minMaxCondition::apply(), and runTimeCondition::setConditionDict().
|
protected |
On/off switch.
Definition at line 78 of file runTimeCondition.H.
Referenced by minTimeStepCondition::apply(), equationMaxIterCondition::apply(), maxDurationCondition::apply(), minMaxCondition::apply(), and averageCondition::apply().
|
protected |
Reference to the condition dictionary.
Definition at line 81 of file runTimeCondition.H.
|
protected |
Group index - if applied, all conditions in a group must be.
satisfied before condition is met
Definition at line 85 of file runTimeCondition.H.
Switch to send output to Info.
Definition at line 145 of file runTimeCondition.H.