Templated basic entry that holds a constant value for backwards compatibility (when DataEntry type is not present) More...
Public Member Functions | |
TypeName ("CompatibilityConstant") | |
CompatibilityConstant (const word &entryName, const dictionary &dict) | |
Construct from entry name and Istream. More... | |
CompatibilityConstant (const CompatibilityConstant< Type > &cnst) | |
Copy constructor. More... | |
virtual tmp< DataEntry< Type > > | clone () const |
Construct and return a clone. More... | |
virtual | ~CompatibilityConstant () |
Destructor. More... | |
Type | value (const scalar) const |
Return constant value. More... | |
Type | integrate (const scalar x1, const scalar x2) const |
Integrate between two values. More... | |
dimensioned< Type > | dimValue (const scalar) const |
Return dimensioned constant value. More... | |
dimensioned< Type > | dimIntegrate (const scalar x1, const scalar x2) const |
Integrate between two values and return dimensioned type. More... | |
virtual void | writeData (Ostream &os) const |
Write in dictionary format. More... | |
Private Member Functions | |
void | operator= (const CompatibilityConstant< Type > &) |
Disallow default bitwise assignment. More... | |
Private Attributes | |
Type | value_ |
Constant value. More... | |
dimensionSet | dimensions_ |
The dimension set. More... | |
Friends | |
Ostream & | operator (Ostream &os, const CompatibilityConstant< Type > &cnst) |
Ostream Operator. More... | |
Templated basic entry that holds a constant value for backwards compatibility (when DataEntry type is not present)
Usage - for entry <entryName> having the value
:
<entryName> <value>
Definition at line 52 of file CompatibilityConstant.H.
CompatibilityConstant | ( | const word & | entryName, |
const dictionary & | dict | ||
) |
Construct from entry name and Istream.
Definition at line 32 of file CompatibilityConstant.C.
References dict, token::isWord(), and Istream::putBack().
CompatibilityConstant | ( | const CompatibilityConstant< Type > & | cnst | ) |
Copy constructor.
Definition at line 64 of file CompatibilityConstant.C.
|
virtual |
Destructor.
Definition at line 77 of file CompatibilityConstant.C.
|
private |
Disallow default bitwise assignment.
TypeName | ( | "CompatibilityConstant" | ) |
Construct and return a clone.
Definition at line 96 of file CompatibilityConstant.H.
Type value | ( | const scalar | x | ) | const |
Return constant value.
Definition at line 84 of file CompatibilityConstant.C.
Type integrate | ( | const scalar | x1, |
const scalar | x2 | ||
) | const |
Integrate between two values.
Definition at line 92 of file CompatibilityConstant.C.
Foam::dimensioned< Type > dimValue | ( | const scalar | x | ) | const |
Return dimensioned constant value.
Definition at line 103 of file CompatibilityConstant.C.
Foam::dimensioned< Type > dimIntegrate | ( | const scalar | x1, |
const scalar | x2 | ||
) | const |
Integrate between two values and return dimensioned type.
Definition at line 111 of file CompatibilityConstant.C.
|
virtual |
Write in dictionary format.
Definition at line 63 of file CompatibilityConstantIO.C.
References Foam::nl, and Ostream::writeKeyword().
|
friend |
Ostream Operator.
|
private |
Constant value.
Definition at line 69 of file CompatibilityConstant.H.
|
private |
The dimension set.
Definition at line 72 of file CompatibilityConstant.H.
Copyright © 2011-2018 OpenFOAM | OPENFOAM® is a registered trademark of OpenCFD Ltd.