mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
ENH: add Function1 wrapping for functionObject trigger
Returns a 0/1 value corresponding to function object trigger levels.
Usage:
\verbatim
<entryName> functionObjectTrigger;
<entryName>Coeffs
{
triggers (1 3 5);
defaultValue false; // Default when no triggers activated
}
\endverbatim
ENH: add reset() method for Constant Function1
ENH: allow forced change of trigger index
- the triggers are normally increase only,
but can now override this optionally
This commit is contained in:
@ -74,12 +74,9 @@ Foam::dictionary& Foam::functionObjects::stateFunctionObject::propertyDict()
|
||||
}
|
||||
|
||||
|
||||
bool Foam::functionObjects::stateFunctionObject::setTrigger
|
||||
(
|
||||
const label triggeri
|
||||
)
|
||||
void Foam::functionObjects::stateFunctionObject::clearTrigger()
|
||||
{
|
||||
return stateDict().setTrigger(triggeri);
|
||||
return stateDict().clearTrigger();
|
||||
}
|
||||
|
||||
|
||||
@ -89,6 +86,16 @@ Foam::label Foam::functionObjects::stateFunctionObject::getTrigger() const
|
||||
}
|
||||
|
||||
|
||||
bool Foam::functionObjects::stateFunctionObject::setTrigger
|
||||
(
|
||||
const label triggeri,
|
||||
bool increaseOnly
|
||||
)
|
||||
{
|
||||
return stateDict().setTrigger(triggeri, increaseOnly);
|
||||
}
|
||||
|
||||
|
||||
bool Foam::functionObjects::stateFunctionObject::foundProperty
|
||||
(
|
||||
const word& entryName
|
||||
|
||||
Reference in New Issue
Block a user