33 const unitConversions&
units,
34 const dictionary&
dict
37 const bool havePeriod =
dict.found(
"period");
38 const bool haveFrequency =
dict.found(
"frequency");
40 if (havePeriod == haveFrequency)
43 << (havePeriod ?
"both" :
"neither") <<
" of keywords "
44 <<
"period " << (havePeriod ?
"and" :
"or")
45 <<
" frequency defined in dictionary " <<
dict.name()
51 ?
dict.lookupOrDefault<scalar>(
"period",
units.x, 0)
68 start_(
dict.lookupOrDefault<scalar>(
"start",
units.
x, scalar(0))),
79 value_(se.value_, false)
Run-time selectable general function of one variable.
Function1 which repeats a given 'value' function with a given period or frequency,...
virtual void write(Ostream &os, const unitConversions &units) const
Write data to dictionary stream.
virtual ~Repeat()
Destructor.
Repeat(const word &name, const unitConversions &units, const dictionary &dict)
Construct from name and dictionary.
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
A list of keywords followed by any number of values (e.g. words and numbers) or sub-dictionaries.
A class for handling words, derived from string.
#define FatalIOErrorInFunction(ios)
Report an error message using Foam::FatalIOError.
void writeEntry(Ostream &os, const omega &a)
autoPtr< CompressibleMomentumTransportModel > New(const volScalarField &rho, const volVectorField &U, const surfaceScalarField &phi, const viscosity &viscosity)
errorManipArg< error, int > exit(error &err, const int errNo=1)
void writeEntryIfDifferent(Ostream &os, const word &entryName, const EntryType &value1, const EntryType &value2)
Helper function to write the keyword and entry only if the.
const HashTable< unitConversion > & units()
Get the table of unit conversions.
word name(const LagrangianState state)
Return a string representation of a Lagrangian state enumeration.
const unitConversion unitless