An exprResult with persistence. More...
Public Member Functions | |
| TypeName ("exprResultStored") | |
| Runtime type information. More... | |
| exprResultStored () | |
| Construct null. More... | |
| exprResultStored (const exprResultStored &rhs) | |
| Copy construct. More... | |
| exprResultStored (const dictionary &dict) | |
| Construct from a dictionary. More... | |
| virtual autoPtr< exprResult > | clone () const |
| Clone. More... | |
| virtual | ~exprResultStored ()=default |
| Destructor. More... | |
| const word & | name () const |
| The name of the expression. More... | |
| const expressions::exprString & | initialValueExpression () const |
| The initial value expression. More... | |
| void | writeDict (Ostream &os) const |
| void | operator= (const exprResultStored &rhs) |
| Copy assignment. More... | |
| void | operator= (const exprResult &rhs) |
| Copy assignment. More... | |
Public Member Functions inherited from exprResult | |
| TypeName ("exprResult") | |
| Runtime type information. More... | |
| declareRunTimeSelectionTable (autoPtr, exprResult, dictionary,(const dictionary &dict),(dict)) | |
| declareRunTimeSelectionTable (autoPtr, exprResult, empty,(),()) | |
| exprResult () | |
| Construct null. More... | |
| exprResult (const exprResult &expr) | |
| Copy construct. More... | |
| exprResult (exprResult &&expr) | |
| Move construct. More... | |
| exprResult (const dictionary &dict, const bool uniform=false, const bool needsValue=false) | |
| Construct from a dictionary. More... | |
| template<class Type > | |
| exprResult (const Field< Type > &f) | |
| Construct by copying a field. More... | |
| template<class Type > | |
| exprResult (Field< Type > &&f) | |
| Construct by moving a field. More... | |
| template<class Type > | |
| exprResult (autoPtr< Type > &ap) | |
| Construct for an IOobject. More... | |
| template<class Type > | |
| exprResult (autoPtr< Type > &&ap) | |
| Construct for an IOobject. More... | |
| template<class Type > | |
| exprResult (const dimensioned< Type > &f) | |
| Construct from a dimensioned value. More... | |
| exprResult (const bool &val) | |
| exprResult (const scalar &val) | |
| exprResult (const vector &val) | |
| exprResult (const tensor &val) | |
| exprResult (const symmTensor &val) | |
| exprResult (const sphericalTensor &val) | |
| virtual | ~exprResult () |
| Destructor. More... | |
| bool | hasValue () const |
| Has a value? More... | |
| const word & | valueType () const |
| Basic type for the field or single value. More... | |
| bool | isPointValue (const bool isPointVal=true) const |
| True if representing point values, or test if same as isPointVal. More... | |
| bool | isUniform () const |
| True if single, uniform value. More... | |
| template<class Type > | |
| bool | isType () const |
| True if valueType corresponds to the given Type. More... | |
| bool | isBool () const |
| True if valueType is a bool. More... | |
| bool | isObject () const |
| True if the object pointer is being used. More... | |
| label | size () const |
| The field or object size. More... | |
| const void * | dataAddress () const |
| The address of the field data content. More... | |
| void | clear () |
| Clear (zero) the result. More... | |
| void | noReset () |
| Change reset behaviour. More... | |
| void | allowReset () |
| Change reset behaviour. More... | |
| void | testIfSingleValue (const bool parRun=Pstream::parRun()) |
| Test if field corresponds to a single-value and thus uniform. More... | |
| template<class Type > | |
| void | setResult (Field< Type > *, bool isPointVal=false) |
| Set result field, taking ownership of the pointer. More... | |
| template<class Type > | |
| void | setResult (const Field< Type > &fld, bool isPointVal=false) |
| Set result field, taking copy of the field contents. More... | |
| template<class Type > | |
| void | setResult (Field< Type > &&, bool isPointVal=false) |
| Set result field, moving field contents. More... | |
| template<class Type > | |
| void | setResult (const Type &val, const label size) |
| Set uniform result field of given size. More... | |
| template<class Type > | |
| void | setSingleValue (const Type &val) |
| Set single-value uniform result. More... | |
| template<class Type > | |
| void | setObjectResult (autoPtr< Type > &o) |
| template<class Type > | |
| void | setObjectResult (autoPtr< Type > &&o) |
| template<class Type > | |
| const Field< Type > & | cref () const |
| Return const reference to the field. More... | |
| template<class Type > | |
| Field< Type > & | ref () |
| Return non-const reference to the field. More... | |
| template<class Type > | |
| Field< Type > & | getRef () const |
| Return non-const reference to the field, casting away constness. More... | |
| template<class Type > | |
| tmp< Field< Type > > | getResult (bool cacheCopy=false) |
| template<class Type > | |
| tmp< Type > | getObjectResult (bool cacheCopy=false) |
| exprResult | getUniform (const label size, const bool noWarn, const bool parRun=Pstream::parRun()) const |
| Construct a uniform field from the current results. More... | |
| template<template< class > class BinaryOp, class Type > | |
| Type | getReduced (const BinaryOp< Type > &bop, const Type &initial=pTraits< Type >::zero) |
| Get a reduced result. More... | |
| void | writeEntry (const word &keyword, Ostream &os) const |
| Forwarding to Field::writeEntry. More... | |
| void | writeDict (Ostream &os, const bool subDict=true) const |
| Write entry as dictionary contents. More... | |
| void | writeValue (Ostream &os) const |
| Write the single value, or the first value from field. More... | |
| virtual void | operator= (exprResult &&rhs) |
| Move assignment. More... | |
| exprResult & | operator*= (const scalar &b) |
| Scalar multiplication. More... | |
| exprResult & | operator+= (const exprResult &b) |
| Addition of results. More... | |
| template<class T > | |
| void | setObjectResultImpl (T *ptr) |
| template<class T > | |
| void | setObjectResultImpl (autoPtr< T > &o) |
| template<class T > | |
| void | setObjectResultImpl (autoPtr< T > &&o) |
| template<class Type > | |
| Foam::tmp< Foam::Field< Type > > | getResult (bool cacheCopy) |
| template<class Type > | |
| const Foam::Field< Type > & | cref () const |
| template<class Type > | |
| Foam::Field< Type > & | ref () |
| template<class Type > | |
| Foam::Field< Type > & | getRef () const |
| template<class Type > | |
| Foam::tmp< Type > | getObjectResult (bool cacheCopy) |
Public Member Functions inherited from refCount | |
| constexpr | refCount () noexcept |
| Construct null initializing count to 0. More... | |
| int | count () const noexcept |
| Return the current reference count. More... | |
| bool | unique () const noexcept |
| Return true if the reference count is zero. More... | |
| void | operator++ () noexcept |
| Increment the reference count. More... | |
| void | operator++ (int) noexcept |
| Increment the reference count. More... | |
| void | operator-- () noexcept |
| Decrement the reference count. More... | |
| void | operator-- (int) noexcept |
| Decrement the reference count. More... | |
Protected Member Functions | |
| virtual void | resetImpl () |
| Reset at new timestep - disabling locally. More... | |
Protected Member Functions inherited from exprResult | |
| virtual exprResult & | target () |
| Simulate virtual templated methods. More... | |
| bool | reset (bool force=false) |
| Reset at new timestep according to type. More... | |
| void | needsReset (bool val) |
| Adjusts the internal needsReset value. More... | |
Additional Inherited Members | |
Static Public Member Functions inherited from exprResult | |
| static autoPtr< exprResult > | New (const dictionary &dict) |
| Return a reference to the selected value driver. More... | |
Static Public Attributes inherited from exprResult | |
| static const exprResult | null |
| An empty result. More... | |
An exprResult with persistence.
Dictionary parameters
| Property | Description | Required | Default |
|---|---|---|---|
name | The result name | yes | |
initialValue | The initial value | yes | |
value | The expression result (dictionary) | no |
Definition at line 82 of file exprResultStored.H.
| exprResultStored | ( | ) |
Construct null.
Definition at line 59 of file exprResultStored.C.
Referenced by exprResultStored::clone().
| exprResultStored | ( | const exprResultStored & | rhs | ) |
Copy construct.
Definition at line 68 of file exprResultStored.C.
|
explicit |
Construct from a dictionary.
Definition at line 79 of file exprResultStored.C.
|
virtualdefault |
Destructor.
|
inlineprotectedvirtual |
Reset at new timestep - disabling locally.
Reimplemented from exprResult.
Definition at line 100 of file exprResultStored.H.
| TypeName | ( | "exprResultStored" | ) |
Runtime type information.
|
inlinevirtual |
Clone.
Reimplemented from exprResult.
Definition at line 123 of file exprResultStored.H.
References exprResultStored::exprResultStored().
|
inline |
The name of the expression.
Definition at line 139 of file exprResultStored.H.
|
inline |
The initial value expression.
Definition at line 145 of file exprResultStored.H.
| void writeDict | ( | Ostream & | os | ) | const |
Definition at line 91 of file exprResultStored.C.
References Ostream::beginBlock(), Ostream::endBlock(), Ostream::writeEntry(), and Ostream::writeKeyword().
| void operator= | ( | const exprResultStored & | rhs | ) |
Copy assignment.
Definition at line 108 of file exprResultStored.C.
References exprResult::operator=().
|
virtual |
Copy assignment.
Reimplemented from exprResult.
Definition at line 125 of file exprResultStored.C.
References exprResult::operator=().