29#ifndef GeometricFieldReuseFunctions_H
30#define GeometricFieldReuseFunctions_H
47 template<
class>
class PatchField,
56 for (
const auto&
p : tgf().boundaryField())
61 && !
isA<
typename PatchField<Type>::Calculated>(
p)
65 <<
"Attempt to reuse temporary with non-reusable BC "
84 template<
class>
class PatchField,
96 const auto& gf1 = tgf1();
113template<
class TypeR,
template<
class>
class PatchField,
class GeoMesh>
123 const bool initCopy =
false
128 auto& gf1 = tgf1.constCast();
131 gf1.dimensions().reset(dimensions);
135 const auto& gf1 = tgf1();
160template<
class TypeR,
template<
class>
class PatchField,
class GeoMesh>
163 GeometricField<TypeR, PatchField, GeoMesh>
169 const bool initCopy =
false
188 template<
class>
class PatchField,
201 const auto& gf1 = tgf1();
223 template<
class>
class PatchField,
228 TypeR, Type1, Type12, TypeR, PatchField,
GeoMesh
241 auto& gf2 = tgf2.constCast();
244 gf2.dimensions().reset(dimensions);
248 const auto& gf1 = tgf1();
269 template<
class>
class PatchField,
274 TypeR, TypeR, TypeR, Type2, PatchField,
GeoMesh
287 auto& gf1 = tgf1.constCast();
290 gf1.dimensions().reset(dimensions);
294 const auto& gf1 = tgf1();
311template<
class TypeR,
template<
class>
class PatchField,
class GeoMesh>
314 TypeR, TypeR, TypeR, TypeR, PatchField,
GeoMesh
327 auto& gf1 = tgf1.constCast();
330 gf1.dimensions().reset(dimensions);
335 auto& gf2 = tgf2.constCast();
338 gf2.dimensions().reset(dimensions);
342 const auto& gf1 = tgf1();
Generic mesh wrapper used by volMesh, surfaceMesh, pointMesh etc.
Generic GeometricField class.
Defines the attributes of an object for which implicit objectRegistry management is supported,...
static autoPtr< Time > New()
Construct (dummy) Time - no functionObjects or libraries.
virtual const word & constraintType() const
Return the constraint type this pointPatch implements.
Dimension set for the base types, which can be used to implement rigorous dimension checking for alge...
A class for managing temporary objects.
A class for handling words, derived from Foam::string.
#define WarningInFunction
Report a warning using Foam::Warning.
const TargetType * isA(const Type &t)
Check if dynamic_cast to TargetType is possible.
Ostream & endl(Ostream &os)
Add newline and flush stream.
bool reusable(const tmp< GeometricField< Type, PatchField, GeoMesh > > &tgf)
tmp< DimensionedField< TypeR, GeoMesh > > New(const tmp< DimensionedField< TypeR, GeoMesh > > &tdf1, const word &name, const dimensionSet &dimensions)
Global function forwards to reuseTmpDimensionedField::New.
word name(const expressions::valueTypeCode typeCode)
A word representation of a valueTypeCode. Empty for INVALID.
static tmp< GeometricField< TypeR, PatchField, GeoMesh > > New(const tmp< GeometricField< TypeR, PatchField, GeoMesh > > &tgf1, const word &name, const dimensionSet &dimensions, const bool initCopy=false)
static tmp< GeometricField< TypeR, PatchField, GeoMesh > > New(const tmp< GeometricField< Type1, PatchField, GeoMesh > > &tgf1, const word &name, const dimensionSet &dimensions)
static tmp< GeometricField< TypeR, PatchField, GeoMesh > > New(const tmp< GeometricField< Type1, PatchField, GeoMesh > > &tgf1, const tmp< GeometricField< TypeR, PatchField, GeoMesh > > &tgf2, const word &name, const dimensionSet &dimensions)
static tmp< GeometricField< TypeR, PatchField, GeoMesh > > New(const tmp< GeometricField< TypeR, PatchField, GeoMesh > > &tgf1, const tmp< GeometricField< Type2, PatchField, GeoMesh > > &tgf2, const word &name, const dimensionSet &dimensions)
static tmp< GeometricField< TypeR, PatchField, GeoMesh > > New(const tmp< GeometricField< TypeR, PatchField, GeoMesh > > &tgf1, const tmp< GeometricField< TypeR, PatchField, GeoMesh > > &tgf2, const word &name, const dimensionSet &dimensions)
static tmp< GeometricField< TypeR, PatchField, GeoMesh > > New(const tmp< GeometricField< Type1, PatchField, GeoMesh > > &tgf1, const tmp< GeometricField< Type2, PatchField, GeoMesh > > &tgf2, const word &name, const dimensionSet &dimensions)