Merge branch 'style-clone-methods' into 'develop'

factory Clone method for handling member clone() methods

See merge request Development/openfoam!658
This commit is contained in:
Andrew Heather
2024-01-09 11:56:52 +00:00
129 changed files with 730 additions and 717 deletions

View File

@ -5,7 +5,7 @@
\\ / A nd | www.openfoam.com
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2017-2019 OpenCFD Ltd
Copyright (C) 2017-2024 OpenCFD Ltd
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -206,9 +206,13 @@ public:
//- Construct as copy
DTRMParticle(const DTRMParticle& p);
//- Return a clone
virtual autoPtr<particle> clone() const
{
return particle::Clone(*this);
}
//- Factory class to read-construct particles used for
// parallel transfer
//- Factory class to read-construct particles (for parallel transfer)
class iNew
{
const polyMesh& mesh_;

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2015 OpenFOAM Foundation
Copyright (C) 2016-2023 OpenCFD Ltd.
Copyright (C) 2016-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -30,9 +30,8 @@ License
#include "Time.H"
#include "PtrList.H"
#include "fvPatchFields.H"
#include "fvsPatchFields.H"
#include "emptyFvPatch.H"
#include "emptyFvPatchField.H"
#include "emptyFvsPatchField.H"
#include "IOobjectList.H"
#include "mapDistributePolyMesh.H"
#include "processorFvPatch.H"
@ -123,15 +122,19 @@ Foam::parFvFieldDistributor::distributeField
{
if (patchFaceMaps_.set(patchi))
{
// Clone local patch field
oldPatchFields.set(patchi, bfld[patchi].clone());
distributedFvPatchFieldMapper mapper
(
labelUList::null(),
patchFaceMaps_[patchi]
);
// Clone local patch field
oldPatchFields.set
(
patchi,
bfld[patchi].clone(fld.internalField())
);
// Map into local copy
oldPatchFields[patchi].autoMap(mapper);
}
@ -159,7 +162,7 @@ Foam::parFvFieldDistributor::distributeField
(
pfld,
tgtMesh_.boundary()[patchi],
DimensionedField<Type, volMesh>::null(),
fvPatchField<Type>::Internal::null(),
dummyMapper
)
);
@ -178,9 +181,9 @@ Foam::parFvFieldDistributor::distributeField
patchi,
fvPatchField<Type>::New
(
emptyFvPatchField<Type>::typeName,
fvPatchFieldBase::emptyType(),
tgtMesh_.boundary()[patchi],
DimensionedField<Type, volMesh>::null()
fvPatchField<Type>::Internal::null()
)
);
}
@ -268,15 +271,19 @@ Foam::parFvFieldDistributor::distributeField
{
if (patchFaceMaps_.set(patchi))
{
// Clone local patch field
oldPatchFields.set(patchi, bfld[patchi].clone());
distributedFvPatchFieldMapper mapper
(
labelUList::null(),
patchFaceMaps_[patchi]
);
// Clone local patch field
oldPatchFields.set
(
patchi,
bfld[patchi].clone(fld.internalField())
);
// Map into local copy
oldPatchFields[patchi].autoMap(mapper);
}
@ -303,7 +310,7 @@ Foam::parFvFieldDistributor::distributeField
(
pfld,
tgtMesh_.boundary()[patchi],
DimensionedField<Type, surfaceMesh>::null(),
fvsPatchField<Type>::Internal::null(),
dummyMapper
)
);
@ -321,9 +328,9 @@ Foam::parFvFieldDistributor::distributeField
patchi,
fvsPatchField<Type>::New
(
emptyFvsPatchField<Type>::typeName,
fvsPatchFieldBase::emptyType(),
tgtMesh_.boundary()[patchi],
DimensionedField<Type, surfaceMesh>::null()
fvsPatchField<Type>::Internal::null()
)
);
}

View File

@ -26,11 +26,11 @@ License
\*---------------------------------------------------------------------------*/
#include "Time.H"
#include "emptyPointPatchField.H"
#include "IOobjectList.H"
#include "mapDistributePolyMesh.H"
#include "distributedFieldMapper.H"
#include "distributedPointPatchFieldMapper.H"
#include "emptyPointPatch.H"
#include "pointFields.H"
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
@ -108,7 +108,7 @@ Foam::parPointFieldDistributor::distributeField
(
bfld[patchi],
tgtMesh.boundary()[patchi], // pointPatch
DimensionedField<Type, pointMesh>::null(),
pointPatchField<Type>::Internal::null(),
mapper
)
);
@ -122,7 +122,7 @@ Foam::parPointFieldDistributor::distributeField
// bfld[patchi].clone
// (
// tgtMesh.boundary()[patchi],
// DimensionedField<Type, pointMesh>::null(),
// pointPatchField<Type>::Internal::null(),
// mapper
// )
//);
@ -140,9 +140,9 @@ Foam::parPointFieldDistributor::distributeField
patchi,
pointPatchField<Type>::New
(
emptyPointPatchField<Type>::typeName,
pointPatchFieldBase::emptyType(),
tgtMesh.boundary()[patchi],
DimensionedField<Type, pointMesh>::null()
pointPatchField<Type>::Internal::null()
)
);
}

View File

@ -5,7 +5,7 @@
\\ / A nd | www.openfoam.com
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2017-2022 OpenCFD Ltd.
Copyright (C) 2017-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -100,10 +100,10 @@ public:
cachedPosition_(p.cachedPosition_)
{}
//- Construct and return a clone
//- Return a clone
virtual autoPtr<particle> clone() const
{
return autoPtr<particle>(new passivePositionParticle(*this));
return particle::Clone(*this);
}

View File

@ -5,7 +5,7 @@
\\ / A nd | www.openfoam.com
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2021 OpenCFD Ltd.
Copyright (C) 2021-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -86,13 +86,10 @@ public:
const ${typeName}Function1_${TemplateType}& rhs
) = default;
//- Construct and return a clone
//- Return a clone
virtual tmp<Function1<${TemplateType}>> clone() const
{
return tmp<Function1<${TemplateType}>>
(
new ${typeName}Function1_${TemplateType}(*this)
);
return Function1<${TemplateType}>::Clone(*this);
}

View File

@ -5,7 +5,7 @@
\\ / A nd | www.openfoam.com
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2020-2021 OpenCFD Ltd.
Copyright (C) 2020-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -85,12 +85,6 @@ public:
const bool faceValues = true
);
//- Copy construct
${typeName}PatchFunction1${FieldType}
(
const ${typeName}PatchFunction1${FieldType}& rhs
) = default;
//- Copy construct, resetting patch
${typeName}PatchFunction1${FieldType}
(
@ -98,25 +92,25 @@ public:
const polyPatch& pp
);
//- Construct and return a clone
//- Copy construct
${typeName}PatchFunction1${FieldType}
(
const ${typeName}PatchFunction1${FieldType}& rhs
) = default;
//- Return a clone
virtual tmp<PatchFunction1<${TemplateType}>> clone() const
{
return tmp<PatchFunction1<${TemplateType}>>
(
new ${typeName}PatchFunction1${FieldType}(*this)
);
return PatchFunction1<${TemplateType}>::Clone(*this);
}
//- Construct and return a clone setting patch
//- Return a clone, setting the patch
virtual tmp<PatchFunction1<${TemplateType}>> clone
(
const polyPatch& pp
) const
{
return tmp<PatchFunction1<${TemplateType}>>
(
new ${typeName}PatchFunction1${FieldType}(*this, pp)
);
return PatchFunction1<${TemplateType}>::Clone(*this, pp);
}

View File

@ -5,7 +5,7 @@
\\ / A nd | www.openfoam.com
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2020-2021 OpenCFD Ltd.
Copyright (C) 2020-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -65,8 +65,8 @@ SourceFiles
\*---------------------------------------------------------------------------*/
#ifndef Function1Types_expression_H
#define Function1Types_expression_H
#ifndef Foam_Function1Types_expression_H
#define Foam_Function1Types_expression_H
#include "Function1.H"
#include "fieldExprDriver.H"
@ -124,10 +124,10 @@ public:
//- Copy construct
explicit Function1Expression(const Function1Expression<Type>& rhs);
//- Construct and return a clone
//- Return a clone
virtual tmp<Function1<Type>> clone() const
{
return tmp<Function1<Type>>(new Function1Expression<Type>(*this));
return Function1<Type>::Clone(*this);
}

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2017 OpenFOAM Foundation
Copyright (C) 2019-2023 OpenCFD Ltd.
Copyright (C) 2019-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -240,6 +240,25 @@ class pointPatchField
:
public pointPatchFieldBase
{
public:
// Public Data Types
//- The patch type for the patch field
typedef pointPatch Patch;
//- The value_type for the patch field
typedef Type value_type;
//- The internal field type associated with the patch field
typedef DimensionedField<Type, pointMesh> Internal;
//- Type for a \em calculated patch
typedef calculatedPointPatchField<Type> Calculated;
private:
// Private Data
//- Reference to internal field
@ -248,19 +267,6 @@ class pointPatchField
public:
//- The Field value_type
typedef Type value_type;
//- The internal field type associated with the patch field
typedef DimensionedField<Type, pointMesh> Internal;
//- The patch type for the patch field
typedef pointPatch Patch;
//- Type for a \em calculated patch
typedef calculatedPointPatchField<Type> Calculated;
// Declare run-time constructor selection tables
declareRunTimeSelectionTable

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2017 OpenFOAM Foundation
Copyright (C) 2017-2021 OpenCFD Ltd.
Copyright (C) 2017-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -133,9 +133,7 @@ public:
//- Return clone
autoPtr<coordinateRotation> clone() const
{
return
autoPtr<coordinateRotation>::NewFrom
<coordinateRotations::euler>(*this);
return coordinateRotation::Clone(*this);
}

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2017 OpenFOAM Foundation
Copyright (C) 2017-2022 OpenCFD Ltd.
Copyright (C) 2017-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -115,9 +115,7 @@ public:
//- Return clone
autoPtr<coordinateRotation> clone() const
{
return
autoPtr<coordinateRotation>::NewFrom
<coordinateRotations::starcd>(*this);
return coordinateRotation::Clone(*this);
}

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2017 OpenFOAM Foundation
Copyright (C) 2017-2022 OpenCFD Ltd.
Copyright (C) 2017-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -144,9 +144,7 @@ public:
//- Return clone
autoPtr<coordinateRotation> clone() const
{
return
autoPtr<coordinateRotation>::NewFrom
<coordinateRotations::axes>(*this);
return coordinateRotation::Clone(*this);
}

View File

@ -5,7 +5,7 @@
\\ / A nd | www.openfoam.com
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2018-2022 OpenCFD Ltd.
Copyright (C) 2018-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -120,9 +120,7 @@ public:
//- Return clone
autoPtr<coordinateRotation> clone() const
{
return
autoPtr<coordinateRotation>::NewFrom
<coordinateRotations::axisAngle>(*this);
return coordinateRotation::Clone(*this);
}

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2016 OpenFOAM Foundation
Copyright (C) 2018-2022 OpenCFD Ltd.
Copyright (C) 2018-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -109,11 +109,18 @@ public:
// Uses all default constructors
//- Construct and return a clone
//- Return a clone
virtual autoPtr<coordinateRotation> clone() const = 0;
// Selectors
// Factory Methods
//- Clone a coordinate rotation
template<class Derived>
static autoPtr<coordinateRotation> Clone(const Derived& crot)
{
return autoPtr<coordinateRotation>(new Derived(crot));
}
//- Select construct the specified coordinate rotation type
//

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2016 OpenFOAM Foundation
Copyright (C) 2018-2021 OpenCFD Ltd.
Copyright (C) 2018-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -89,9 +89,7 @@ public:
//- Return clone
autoPtr<coordinateRotation> clone() const
{
return
autoPtr<coordinateRotation>::NewFrom
<coordinateRotations::cylindrical>(*this);
return coordinateRotation::Clone(*this);
}

View File

@ -5,7 +5,7 @@
\\ / A nd | www.openfoam.com
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2018-2021 OpenCFD Ltd.
Copyright (C) 2018-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -93,9 +93,7 @@ public:
//- Return clone
autoPtr<coordinateRotation> clone() const
{
return
autoPtr<coordinateRotation>::NewFrom
<coordinateRotations::identity>(*this);
return coordinateRotation::Clone(*this);
}

View File

@ -5,7 +5,7 @@
\\ / A nd | www.openfoam.com
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2021 OpenCFD Ltd.
Copyright (C) 2021-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -89,9 +89,7 @@ public:
//- Return clone
autoPtr<coordinateRotation> clone() const
{
return
autoPtr<coordinateRotation>::NewFrom
<coordinateRotations::specified>(*this);
return coordinateRotation::Clone(*this);
}

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2013 OpenFOAM Foundation
Copyright (C) 2018-2022 OpenCFD Ltd.
Copyright (C) 2018-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -149,7 +149,7 @@ public:
//- Return clone
virtual autoPtr<coordinateSystem> clone() const
{
return autoPtr<coordinateSystem>::NewFrom<cartesian>(*this);
return coordinateSystem::Clone(*this);
}

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2016 OpenFOAM Foundation
Copyright (C) 2018-2022 OpenCFD Ltd.
Copyright (C) 2018-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -453,7 +453,26 @@ public:
);
// Selectors
// Factory Methods
//- Clone a coordinate system
template<class Derived>
static autoPtr<coordinateSystem> Clone(const Derived& csys)
{
return autoPtr<coordinateSystem>(new Derived(csys));
}
//- Select construct the specified coordinate system type
//- with reference to objectRegistry for indirect entries.
//
// An empty modelType will be treated as "cartesian"
static autoPtr<coordinateSystem> Clone
(
const word& modelType,
const objectRegistry& obr,
const dictionary& dict,
IOobjectOption::readOption readOrigin = IOobjectOption::MUST_READ
);
//- Select construct the specified coordinate system type
//- with reference to objectRegistry for indirect entries.

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2014 OpenFOAM Foundation
Copyright (C) 2018-2022 OpenCFD Ltd.
Copyright (C) 2018-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -191,7 +191,7 @@ public:
//- Return clone
virtual autoPtr<coordinateSystem> clone() const
{
return autoPtr<coordinateSystem>::NewFrom<cylindrical>(*this);
return coordinateSystem::Clone(*this);
}

View File

@ -5,7 +5,7 @@
\\ / A nd | www.openfoam.com
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2018-2022 OpenCFD Ltd.
Copyright (C) 2018-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -149,7 +149,7 @@ public:
//- Return clone
virtual autoPtr<coordinateSystem> clone() const
{
return autoPtr<coordinateSystem>::NewFrom<indirect>(*this);
return coordinateSystem::Clone(*this);
}

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2017 OpenFOAM Foundation
Copyright (C) 2017-2023 OpenCFD Ltd.
Copyright (C) 2017-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -140,10 +140,10 @@ public:
//- Copy construct
explicit CSV(const CSV<Type>& csv);
//- Construct and return a clone
//- Return a clone
virtual tmp<Function1<Type>> clone() const
{
return tmp<Function1<Type>>(new CSV<Type>(*this));
return Function1<Type>::Clone(*this);
}

View File

@ -5,7 +5,7 @@
\\ / A nd | www.openfoam.com
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2021 OpenCFD Ltd.
Copyright (C) 2021-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -84,8 +84,8 @@ SourceFiles
\*---------------------------------------------------------------------------*/
#ifndef Function1Types_CodedFunction1_H
#define Function1Types_CodedFunction1_H
#ifndef Foam_Function1Types_CodedFunction1_H
#define Foam_Function1Types_CodedFunction1_H
#include "Function1.H"
#include "codedBase.H"
@ -184,10 +184,10 @@ public:
//- Copy construct
explicit CodedFunction1(const CodedFunction1<Type>& rhs);
//- Construct and return a clone
//- Return a clone
virtual tmp<Function1<Type>> clone() const
{
return tmp<Function1<Type>>(new CodedFunction1<Type>(*this));
return Function1<Type>::Clone(*this);
}

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2017 OpenFOAM Foundation
Copyright (C) 2015-2021 OpenCFD Ltd.
Copyright (C) 2015-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -53,8 +53,8 @@ SourceFiles
\*---------------------------------------------------------------------------*/
#ifndef Function1Types_Constant_H
#define Function1Types_Constant_H
#ifndef Foam_Function1Types_Constant_H
#define Foam_Function1Types_Constant_H
#include "Function1.H"
@ -118,10 +118,10 @@ public:
//- Copy constructor
explicit Constant(const Constant<Type>& rhs);
//- Construct and return a clone
//- Return a clone
virtual tmp<Function1<Type>> clone() const
{
return tmp<Function1<Type>>(new Constant<Type>(*this));
return Function1<Type>::Clone(*this);
}

View File

@ -5,7 +5,7 @@
\\ / A nd | www.openfoam.com
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2020-2022 OpenCFD Ltd.
Copyright (C) 2020-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -96,8 +96,8 @@ SourceFiles
\*---------------------------------------------------------------------------*/
#ifndef Function1Types_Cosine_H
#define Function1Types_Cosine_H
#ifndef Foam_Function1Types_Cosine_H
#define Foam_Function1Types_Cosine_H
#include "Sine.H"
@ -148,10 +148,10 @@ public:
Sine<Type>(rhs)
{}
//- Construct and return a clone
//- Return a clone
virtual tmp<Function1<Type>> clone() const
{
return tmp<Function1<Type>>(new Cosine<Type>(*this));
return Function1<Type>::Clone(*this);
}

View File

@ -134,17 +134,6 @@ Foam::FieldFunction1<Function1Type>::FieldFunction1
{}
template<class Function1Type>
Foam::tmp<Foam::Function1<typename Function1Type::returnType>>
Foam::FieldFunction1<Function1Type>::clone() const
{
return tmp<Function1<Type>>
(
new FieldFunction1<Function1Type>(*this)
);
}
template<class Function1Type>
Foam::tmp<Foam::Field<typename Function1Type::returnType>>
Foam::FieldFunction1<Function1Type>::integrate

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2017 OpenFOAM Foundation
Copyright (C) 2018-2023 OpenCFD Ltd.
Copyright (C) 2018-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -164,11 +164,18 @@ public:
//- Copy construct
explicit Function1(const Function1<Type>& rhs);
//- Construct and return a clone
//- Return a clone
virtual tmp<Function1<Type>> clone() const = 0;
// Selectors
// Factory Methods
//- Clone a Function1
template<class Derived>
static tmp<Function1<Type>> Clone(const Derived& fun)
{
return tmp<Function1<Type>>(new Derived(fun));
}
//- Selector, with fallback redirection
static autoPtr<Function1<Type>> New
@ -321,8 +328,11 @@ public:
const objectRegistry* obrPtr = nullptr
);
//- Construct and return a clone
virtual tmp<Function1<Type>> clone() const;
//- Return a clone
virtual tmp<Function1<Type>> clone() const
{
return Function1<Type>::Clone(*this);
}
//- Destructor

View File

@ -25,8 +25,8 @@ License
\*---------------------------------------------------------------------------*/
#ifndef Function1Fwd_H
#define Function1Fwd_H
#ifndef Foam_Function1Fwd_H
#define Foam_Function1Fwd_H
#include "Function1.H"
#include "vector.H"

View File

@ -5,7 +5,7 @@
\\ / A nd | www.openfoam.com
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2021 OpenCFD Ltd.
Copyright (C) 2021-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -58,8 +58,8 @@ SourceFiles
\*---------------------------------------------------------------------------*/
#ifndef Function1Types_FunctionObjectTrigger_H
#define Function1Types_FunctionObjectTrigger_H
#ifndef Foam_Function1Types_FunctionObjectTrigger_H
#define Foam_Function1Types_FunctionObjectTrigger_H
#include "Function1.H"
#include "labelList.H"
@ -80,7 +80,6 @@ class FunctionObjectTrigger
:
public Function1<Type>
{
// Private Data
//- Trigger indices when it is considered active
@ -124,10 +123,10 @@ public:
//- Copy construct
explicit FunctionObjectTrigger(const FunctionObjectTrigger<Type>& rhs);
//- Construct and return a clone
//- Return a clone
virtual tmp<Function1<Type>> clone() const
{
return tmp<Function1<Type>>(new FunctionObjectTrigger<Type>(*this));
return Function1<Type>::Clone(*this);
}

View File

@ -5,7 +5,7 @@
\\ / A nd | www.openfoam.com
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2021 OpenCFD Ltd.
Copyright (C) 2021-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -49,8 +49,8 @@ SourceFiles
\*---------------------------------------------------------------------------*/
#ifndef Function1Types_FunctionObjectValue_H
#define Function1Types_FunctionObjectValue_H
#ifndef Foam_Function1Types_FunctionObjectValue_H
#define Foam_Function1Types_FunctionObjectValue_H
#include "Function1.H"
@ -116,10 +116,10 @@ public:
//- Copy construct
explicit FunctionObjectValue(const FunctionObjectValue<Type>& rhs);
//- Construct and return a clone
//- Return a clone
virtual tmp<Function1<Type>> clone() const
{
return tmp<Function1<Type>>(new FunctionObjectValue<Type>(*this));
return Function1<Type>::Clone(*this);
}

View File

@ -5,7 +5,7 @@
\\ / A nd | www.openfoam.com
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2020-2021 OpenCFD Ltd.
Copyright (C) 2020-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -104,8 +104,8 @@ SourceFiles
\*---------------------------------------------------------------------------*/
#ifndef Function1Types_InputValueMapper_H
#define Function1Types_InputValueMapper_H
#ifndef Foam_Function1Types_InputValueMapper_H
#define Foam_Function1Types_InputValueMapper_H
#include "Function1.H"
#include "Enum.H"
@ -201,10 +201,10 @@ public:
//- Copy construct
explicit InputValueMapper(const InputValueMapper<Type>& rhs);
//- Construct and return a clone
//- Return a clone
virtual tmp<Function1<Type>> clone() const
{
return tmp<Function1<Type>>(new InputValueMapper<Type>(*this));
return Function1<Type>::Clone(*this);
}

View File

@ -5,7 +5,7 @@
\\ / A nd | www.openfoam.com
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2021-2022 OpenCFD Ltd.
Copyright (C) 2021-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -86,10 +86,10 @@ public:
const objectRegistry* obrPtr = nullptr
);
//- Construct and return a clone
//- Return a clone
virtual tmp<Function1<Type>> clone() const
{
return tmp<Function1<Type>>(new None<Type>(*this));
return Function1<Type>::Clone(*this);
}

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2017 OpenFOAM Foundation
Copyright (C) 2020-2022 OpenCFD Ltd.
Copyright (C) 2020-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -40,8 +40,8 @@ SourceFiles
\*---------------------------------------------------------------------------*/
#ifndef Function1Types_OneConstant_H
#define Function1Types_OneConstant_H
#ifndef Foam_Function1Types_OneConstant_H
#define Foam_Function1Types_OneConstant_H
#include "Function1.H"
@ -93,10 +93,10 @@ public:
const objectRegistry* obrPtr = nullptr
);
//- Construct and return a clone
//- Return a clone
virtual tmp<Function1<Type>> clone() const
{
return tmp<Function1<Type>>(new OneConstant<Type>(*this));
return Function1<Type>::Clone(*this);
}

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2017 OpenFOAM Foundation
Copyright (C) 2021 OpenCFD Ltd.
Copyright (C) 2021-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -59,8 +59,8 @@ SourceFiles
\*---------------------------------------------------------------------------*/
#ifndef Function1Types_Polynomial_H
#define Function1Types_Polynomial_H
#ifndef Foam_Function1Types_Polynomial_H
#define Foam_Function1Types_Polynomial_H
#include "Function1.H"
#include "Tuple2.H"
@ -127,10 +127,10 @@ public:
//- Copy constructor
explicit Polynomial(const Polynomial& poly);
//- Construct and return a clone
//- Return a clone
virtual tmp<Function1<Type>> clone() const
{
return tmp<Function1<Type>>(new Polynomial<Type>(*this));
return Function1<Type>::Clone(*this);
}

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2017 OpenFOAM Foundation
Copyright (C) 2020-2021 OpenCFD Ltd.
Copyright (C) 2020-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -72,8 +72,8 @@ SourceFiles
\*---------------------------------------------------------------------------*/
#ifndef Function1Types_Scale_H
#define Function1Types_Scale_H
#ifndef Foam_Function1Types_Scale_H
#define Foam_Function1Types_Scale_H
#include "Function1.H"
@ -133,10 +133,10 @@ public:
//- Copy construct
explicit Scale(const Scale<Type>& rhs);
//- Construct and return a clone
//- Return a clone
virtual tmp<Function1<Type>> clone() const
{
return tmp<Function1<Type>>(new Scale<Type>(*this));
return Function1<Type>::Clone(*this);
}

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2016-2017 OpenFOAM Foundation
Copyright (C) 2020-2022 OpenCFD Ltd.
Copyright (C) 2020-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -98,8 +98,8 @@ SourceFiles
\*---------------------------------------------------------------------------*/
#ifndef Function1Types_Sine_H
#define Function1Types_Sine_H
#ifndef Foam_Function1Types_Sine_H
#define Foam_Function1Types_Sine_H
#include "Function1.H"
@ -192,10 +192,10 @@ public:
//- Copy construct
explicit Sine(const Sine<Type>& rhs);
//- Construct and return a clone
//- Return a clone
virtual tmp<Function1<Type>> clone() const
{
return tmp<Function1<Type>>(new Sine<Type>(*this));
return Function1<Type>::Clone(*this);
}

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2016-2017 OpenFOAM Foundation
Copyright (C) 2020-2021 OpenCFD Ltd.
Copyright (C) 2020-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -101,8 +101,8 @@ Note
\*---------------------------------------------------------------------------*/
#ifndef Function1Types_Square_H
#define Function1Types_Square_H
#ifndef Foam_Function1Types_Square_H
#define Foam_Function1Types_Square_H
#include "Sine.H"
@ -155,10 +155,10 @@ public:
//- Copy construct
explicit Square(const Square<Type>& rhs);
//- Construct and return a clone
//- Return a clone
virtual tmp<Function1<Type>> clone() const
{
return tmp<Function1<Type>>(new Square<Type>(*this));
return Function1<Type>::Clone(*this);
}

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2017 OpenFOAM Foundation
Copyright (C) 2019-2021 OpenCFD Ltd.
Copyright (C) 2019-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -79,8 +79,8 @@ SourceFiles
\*---------------------------------------------------------------------------*/
#ifndef Function1Types_Table_H
#define Function1Types_Table_H
#ifndef Foam_Function1Types_Table_H
#define Foam_Function1Types_Table_H
#include "TableBase.H"
@ -130,10 +130,10 @@ public:
//- Copy construct
explicit Table(const Table<Type>& tbl);
//- Construct and return a clone
//- Return a clone
virtual tmp<Function1<Type>> clone() const
{
return tmp<Function1<Type>>(new Table<Type>(*this));
return Function1<Type>::Clone(*this);
}

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2017 OpenFOAM Foundation
Copyright (C) 2019-2021 OpenCFD Ltd.
Copyright (C) 2019-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -59,8 +59,8 @@ SourceFiles
\*---------------------------------------------------------------------------*/
#ifndef Function1Types_TableFile_H
#define Function1Types_TableFile_H
#ifndef Foam_Function1Types_TableFile_H
#define Foam_Function1Types_TableFile_H
#include "TableBase.H"
@ -111,10 +111,10 @@ public:
//- Copy construct
explicit TableFile(const TableFile<Type>& tbl);
//- Construct and return a clone
//- Return a clone
virtual tmp<Function1<Type>> clone() const
{
return tmp<Function1<Type>>(new TableFile<Type>(*this));
return Function1<Type>::Clone(*this);
}

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2017 OpenFOAM Foundation
Copyright (C) 2020-2022 OpenCFD Ltd.
Copyright (C) 2020-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -40,8 +40,8 @@ Description
\*---------------------------------------------------------------------------*/
#ifndef Function1Types_Uniform_H
#define Function1Types_Uniform_H
#ifndef Foam_Function1Types_Uniform_H
#define Foam_Function1Types_Uniform_H
#include "Constant.H"
@ -89,10 +89,10 @@ public:
Constant<Type>(entryName, dict, obrPtr)
{}
//- Construct and return a clone
//- Return a clone
virtual tmp<Function1<Type>> clone() const
{
return tmp<Function1<Type>>(new Uniform<Type>(*this));
return Function1<Type>::Clone(*this);
}
};

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2017 OpenFOAM Foundation
Copyright (C) 2020-2022 OpenCFD Ltd.
Copyright (C) 2020-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -49,8 +49,8 @@ SourceFiles
\*---------------------------------------------------------------------------*/
#ifndef Function1Types_ZeroConstant_H
#define Function1Types_ZeroConstant_H
#ifndef Foam_Function1Types_ZeroConstant_H
#define Foam_Function1Types_ZeroConstant_H
#include "Function1.H"
@ -102,10 +102,10 @@ public:
const objectRegistry* obrPtr = nullptr
);
//- Construct and return a clone
//- Return a clone
virtual tmp<Function1<Type>> clone() const
{
return tmp<Function1<Type>>(new ZeroConstant<Type>(*this));
return Function1<Type>::Clone(*this);
}

View File

@ -26,8 +26,8 @@ License
\*---------------------------------------------------------------------------*/
#include "Time.H"
#include "emptyFaPatchField.H"
#include "emptyFaePatchField.H"
#include "faPatchFields.H"
#include "faePatchFields.H"
#include "IOobjectList.H"
#include "polyMesh.H"
#include "polyPatch.H"
@ -49,10 +49,6 @@ Foam::faMeshDistributor::distributeField
const GeometricField<Type, faPatchField, areaMesh>& fld
) const
{
typedef typename
GeometricField<Type, faPatchField, areaMesh>::Patch
PatchFieldType;
if (tgtMesh_.boundary().size() && patchEdgeMaps_.empty())
{
createPatchMaps();
@ -87,7 +83,7 @@ Foam::faMeshDistributor::distributeField
// Create patchFields by remote mapping
PtrList<PatchFieldType> newPatchFields(tgtMesh_.boundary().size());
PtrList<faPatchField<Type>> newPatchFields(tgtMesh_.boundary().size());
const auto& bfld = fld.boundaryField();
@ -107,11 +103,11 @@ Foam::faMeshDistributor::distributeField
newPatchFields.set
(
patchi,
PatchFieldType::New
faPatchField<Type>::New
(
bfld[patchi],
tgtMesh_.boundary()[patchi],
DimensionedField<Type, areaMesh>::null(),
faPatchField<Type>::Internal::null(),
mapper
)
);
@ -127,11 +123,11 @@ Foam::faMeshDistributor::distributeField
newPatchFields.set
(
patchi,
PatchFieldType::New
faPatchField<Type>::New
(
emptyFaPatchField<Type>::typeName,
faPatchFieldBase::emptyType(),
tgtMesh_.boundary()[patchi],
DimensionedField<Type, areaMesh>::null()
faPatchField<Type>::Internal::null()
)
);
}
@ -158,10 +154,6 @@ Foam::faMeshDistributor::distributeField
const GeometricField<Type, faePatchField, edgeMesh>& fld
) const
{
typedef typename
GeometricField<Type, faePatchField, edgeMesh>::Patch
PatchFieldType;
if (!internalEdgeMap_)
{
createInternalEdgeMap();
@ -197,7 +189,7 @@ Foam::faMeshDistributor::distributeField
// Create patchFields by remote mapping
PtrList<PatchFieldType> newPatchFields(tgtMesh_.boundary().size());
PtrList<faePatchField<Type>> newPatchFields(tgtMesh_.boundary().size());
const auto& bfld = fld.boundaryField();
@ -217,11 +209,11 @@ Foam::faMeshDistributor::distributeField
newPatchFields.set
(
patchi,
PatchFieldType::New
faePatchField<Type>::New
(
bfld[patchi],
tgtMesh_.boundary()[patchi],
DimensionedField<Type, edgeMesh>::null(),
faePatchField<Type>::Internal::null(),
mapper
)
);
@ -237,11 +229,11 @@ Foam::faMeshDistributor::distributeField
newPatchFields.set
(
patchi,
PatchFieldType::New
faePatchField<Type>::New
(
emptyFaePatchField<Type>::typeName,
faePatchFieldBase::emptyType(),
tgtMesh_.boundary()[patchi],
DimensionedField<Type, edgeMesh>::null()
faePatchField<Type>::Internal::null()
)
);
}

View File

@ -60,7 +60,7 @@ Foam::faMeshSubset::interpolate
(
faPatchFieldBase::calculatedType(),
sMesh.boundary()[patchi],
DimensionedField<Type, areaMesh>::null()
faPatchField<Type>::Internal::null()
)
);
}
@ -167,7 +167,7 @@ Foam::faMeshSubset::interpolate
(
faePatchFieldBase::calculatedType(),
sMesh.boundary()[patchi],
DimensionedField<Type, edgeMesh>::null()
faePatchField<Type>::Internal::null()
)
);
}

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2016-2017 Wikki Ltd
Copyright (C) 2019-2023 OpenCFD Ltd.
Copyright (C) 2019-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -238,11 +238,31 @@ class faPatchField
public faPatchFieldBase,
public Field<Type>
{
public:
// Public Data Types
//- The patch type for the patch field
typedef faPatch Patch;
//- The value_type for the patch field
typedef Type value_type;
//- The internal field type associated with the patch field
typedef DimensionedField<Type, areaMesh> Internal;
//- Type for a \em calculated patch
typedef calculatedFaPatchField<Type> Calculated;
private:
// Private Data
//- Reference to internal field
const DimensionedField<Type, areaMesh>& internalField_;
protected:
// Protected Member Functions
@ -268,16 +288,6 @@ protected:
public:
//- The internal field type associated with the patch field
typedef DimensionedField<Type, areaMesh> Internal;
//- The patch type for the patch field
typedef faPatch Patch;
//- Type for a \em calculated patch
typedef calculatedFaPatchField<Type> Calculated;
// Declare run-time constructor selection tables
declareRunTimeSelectionTable

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2016-2017 Wikki Ltd
Copyright (C) 2019-2023 OpenCFD Ltd.
Copyright (C) 2019-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -211,6 +211,25 @@ class faePatchField
public faePatchFieldBase,
public Field<Type>
{
public:
// Public Data Types
//- The patch type for the patch field
typedef faPatch Patch;
//- The value_type for the patch field
typedef Type value_type;
//- The internal field type associated with the patch field
typedef DimensionedField<Type, edgeMesh> Internal;
//- Type for a \em calculated patch
typedef calculatedFaePatchField<Type> Calculated;
private:
// Private Data
//- Reference to internal field
@ -238,16 +257,6 @@ protected:
public:
//- The internal field type associated with the patch field
typedef DimensionedField<Type, edgeMesh> Internal;
//- The patch type for the patch field
typedef faPatch Patch;
//- Type for a \em calculated patch
typedef calculatedFaePatchField<Type> Calculated;
// Declare run-time constructor selection tables
declareRunTimeSelectionTable

View File

@ -62,16 +62,6 @@ Foam::PatchFunction1Types::PatchExprField<Type>::PatchExprField
}
template<class Type>
Foam::PatchFunction1Types::PatchExprField<Type>::PatchExprField
(
const PatchExprField<Type>& rhs
)
:
PatchExprField<Type>(rhs, rhs.patch())
{}
template<class Type>
Foam::PatchFunction1Types::PatchExprField<Type>::PatchExprField
(
@ -86,6 +76,16 @@ Foam::PatchFunction1Types::PatchExprField<Type>::PatchExprField
{}
template<class Type>
Foam::PatchFunction1Types::PatchExprField<Type>::PatchExprField
(
const PatchExprField<Type>& rhs
)
:
PatchExprField<Type>(rhs, rhs.patch())
{}
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
template<class Type>

View File

@ -5,7 +5,7 @@
\\ / A nd | www.openfoam.com
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2020 OpenCFD Ltd.
Copyright (C) 2020-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -122,9 +122,6 @@ public:
const bool faceValues = true
);
//- Copy construct
explicit PatchExprField(const PatchExprField<Type>& rhs);
//- Copy construct setting patch
explicit PatchExprField
(
@ -132,22 +129,19 @@ public:
const polyPatch& pp
);
//- Construct and return a clone
//- Copy construct
explicit PatchExprField(const PatchExprField<Type>& rhs);
//- Return a clone
virtual tmp<PatchFunction1<Type>> clone() const
{
return tmp<PatchFunction1<Type>>
(
new PatchExprField<Type>(*this)
);
return PatchFunction1<Type>::Clone(*this);
}
//- Construct and return a clone setting patch
//- Return a clone, setting the patch
virtual tmp<PatchFunction1<Type>> clone(const polyPatch& pp) const
{
return tmp<PatchFunction1<Type>>
(
new PatchExprField<Type>(*this, pp)
);
return PatchFunction1<Type>::Clone(*this, pp);
}

View File

@ -73,16 +73,6 @@ Foam::PatchFunction1Types::Sampled<Type>::Sampled
}
template<class Type>
Foam::PatchFunction1Types::Sampled<Type>::Sampled
(
const Sampled<Type>& rhs
)
:
Sampled<Type>(rhs, rhs.patch())
{}
template<class Type>
Foam::PatchFunction1Types::Sampled<Type>::Sampled
(
@ -99,6 +89,16 @@ Foam::PatchFunction1Types::Sampled<Type>::Sampled
{}
template<class Type>
Foam::PatchFunction1Types::Sampled<Type>::Sampled
(
const Sampled<Type>& rhs
)
:
Sampled<Type>(rhs, rhs.patch())
{}
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
template<class Type>

View File

@ -5,7 +5,7 @@
\\ / A nd | www.openfoam.com
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2018-2020 OpenCFD Ltd.
Copyright (C) 2018-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -149,9 +149,6 @@ public:
const bool faceValues = true
);
//- Copy construct
explicit Sampled(const Sampled<Type>& rhs);
//- Copy construct setting patch
explicit Sampled
(
@ -159,22 +156,19 @@ public:
const polyPatch& pp
);
//- Construct and return a clone
//- Copy construct
explicit Sampled(const Sampled<Type>& rhs);
//- Return a clone
virtual tmp<PatchFunction1<Type>> clone() const
{
return tmp<PatchFunction1<Type>>
(
new Sampled<Type>(*this)
);
return PatchFunction1<Type>::Clone(*this);
}
//- Construct and return a clone setting patch
//- Return a clone, setting the patch
virtual tmp<PatchFunction1<Type>> clone(const polyPatch& pp) const
{
return tmp<PatchFunction1<Type>>
(
new Sampled<Type>(*this, pp)
);
return PatchFunction1<Type>::Clone(*this, pp);
}

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2017 OpenFOAM Foundation
Copyright (C) 2019-2023 OpenCFD Ltd.
Copyright (C) 2019-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -281,11 +281,31 @@ class fvPatchField
public fvPatchFieldBase,
public Field<Type>
{
public:
// Public Data Types
//- The patch type for the patch field
typedef fvPatch Patch;
//- The value_type for the patch field
typedef Type value_type;
//- The internal field type associated with the patch field
typedef DimensionedField<Type, volMesh> Internal;
//- Type for a \em calculated patch
typedef calculatedFvPatchField<Type> Calculated;
private:
// Private Data
//- Reference to internal field
const DimensionedField<Type, volMesh>& internalField_;
protected:
// Protected Member Functions
@ -311,16 +331,6 @@ protected:
public:
//- The internal field type associated with the patch field
typedef DimensionedField<Type, volMesh> Internal;
//- The patch type for the patch field
typedef fvPatch Patch;
//- Type for a \em calculated patch
typedef calculatedFvPatchField<Type> Calculated;
// Declare run-time constructor selection tables
declareRunTimeSelectionTable

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2016 OpenFOAM Foundation
Copyright (C) 2019-2023 OpenCFD Ltd.
Copyright (C) 2019-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -205,11 +205,31 @@ class fvsPatchField
public fvsPatchFieldBase,
public Field<Type>
{
public:
// Public Data Types
//- The patch type for the patch field
typedef fvPatch Patch;
//- The value_type for the patch field
typedef Type value_type;
//- The internal field type associated with the patch field
typedef DimensionedField<Type, surfaceMesh> Internal;
//- Type for a \em calculated patch
typedef calculatedFvsPatchField<Type> Calculated;
private:
// Private Data
//- Reference to internal field
const DimensionedField<Type, surfaceMesh>& internalField_;
protected:
// Protected Member Functions
@ -232,16 +252,6 @@ protected:
public:
//- The internal field type associated with the patch field
typedef DimensionedField<Type, surfaceMesh> Internal;
//- The patch type for the patch field
typedef fvPatch Patch;
//- Type for a \em calculated patch
typedef calculatedFvsPatchField<Type> Calculated;
// Declare run-time constructor selection tables
declareRunTimeSelectionTable

View File

@ -67,7 +67,7 @@ Foam::fvMeshSubset::interpolate
new emptyFvPatchField<Type>
(
sMesh.boundary()[patchi],
DimensionedField<Type, volMesh>::null()
fvPatchField<Type>::Internal::null()
)
);
}
@ -80,7 +80,7 @@ Foam::fvMeshSubset::interpolate
(
fvPatchFieldBase::calculatedType(),
sMesh.boundary()[patchi],
DimensionedField<Type, volMesh>::null()
fvPatchField<Type>::Internal::null()
)
);
}
@ -248,7 +248,7 @@ Foam::fvMeshSubset::interpolate
new emptyFvsPatchField<Type>
(
sMesh.boundary()[patchi],
DimensionedField<Type, surfaceMesh>::null()
fvsPatchField<Type>::Internal::null()
)
);
}
@ -261,7 +261,7 @@ Foam::fvMeshSubset::interpolate
(
fvsPatchFieldBase::calculatedType(),
sMesh.boundary()[patchi],
DimensionedField<Type, surfaceMesh>::null()
fvsPatchField<Type>::Internal::null()
)
);
}
@ -435,7 +435,7 @@ Foam::fvMeshSubset::interpolate
new emptyPointPatchField<Type>
(
sMesh.boundary()[patchi],
DimensionedField<Type, pointMesh>::null()
pointPatchField<Type>::Internal::null()
)
);
}
@ -448,7 +448,7 @@ Foam::fvMeshSubset::interpolate
(
pointPatchFieldBase::calculatedType(),
sMesh.boundary()[patchi],
DimensionedField<Type, pointMesh>::null()
pointPatchField<Type>::Internal::null()
)
);
}

View File

@ -55,7 +55,7 @@ tmp<GeometricField<Type, fvPatchField, volMesh>> singleCellFvMesh::interpolate
(
fvPatchFieldBase::calculatedType(),
boundary()[patchi],
DimensionedField<Type, volMesh>::null()
fvPatchField<Type>::Internal::null()
)
);
}

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2013-2017 OpenFOAM Foundation
Copyright (C) 2019 OpenCFD Ltd.
Copyright (C) 2019-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -144,14 +144,13 @@ public:
bool newFormat = true
);
//- Construct and return a clone
autoPtr<particle> clone() const
//- Return a clone
virtual autoPtr<particle> clone() const
{
return autoPtr<particle>(new findCellParticle(*this));
return particle::Clone(*this);
}
//- Factory class to read-construct particles used for
// parallel transfer
//- Factory class to read-construct particles (for parallel transfer)
class iNew
{
const polyMesh& mesh_;

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2017 OpenFOAM Foundation
Copyright (C) 2022 OpenCFD Ltd.
Copyright (C) 2022-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -170,10 +170,10 @@ public:
//- Construct copy
streamLineParticle(const streamLineParticle& p);
//- Construct and return a clone
autoPtr<particle> clone() const
//- Return a clone
virtual autoPtr<particle> clone() const
{
return autoPtr<particle>(new streamLineParticle(*this));
return particle::Clone(*this);
}
//- Factory class to read-construct particles used for parallel transfer

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2016 OpenFOAM Foundation
Copyright (C) 2017-2019 OpenCFD Ltd.
Copyright (C) 2017-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -41,7 +41,6 @@ SourceFiles
#define Foam_wallBoundedParticle_H
#include "particle.H"
#include "autoPtr.H"
#include "InfoProxy.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
@ -176,14 +175,13 @@ public:
//- Construct copy
wallBoundedParticle(const wallBoundedParticle& p);
//- Construct and return a clone
autoPtr<particle> clone() const
//- Return a clone
virtual autoPtr<particle> clone() const
{
return autoPtr<particle>(new wallBoundedParticle(*this));
return particle::Clone(*this);
}
//- Factory class to read-construct particles used for
// parallel transfer
//- Factory class to read-construct particles (for parallel transfer)
class iNew
{
const polyMesh& mesh_;

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2016 OpenFOAM Foundation
Copyright (C) 2017-2022 OpenCFD Ltd.
Copyright (C) 2017-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -40,7 +40,6 @@ SourceFiles
#define Foam_wallBoundedStreamLineParticle_H
#include "wallBoundedParticle.H"
#include "autoPtr.H"
#include "interpolation.H"
#include "vectorList.H"
#include "InfoProxy.H"
@ -181,14 +180,13 @@ public:
//- Construct copy
wallBoundedStreamLineParticle(const wallBoundedStreamLineParticle& p);
//- Construct and return a clone
//- Return a clone
autoPtr<particle> clone() const
{
return autoPtr<particle>(new wallBoundedStreamLineParticle(*this));
return particle::Clone(*this);
}
//- Factory class to read-construct particles used for
// parallel transfer
//- Factory class to read-construct particles (for parallel transfer)
class iNew
{
const polyMesh& mesh_;

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2017 OpenFOAM Foundation
Copyright (C) 2016 OpenCFD Ltd.
Copyright (C) 2016-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -42,7 +42,6 @@ SourceFiles
#include "particle.H"
#include "IOstream.H"
#include "autoPtr.H"
#include "contiguous.H"
#include "DSMCCloud.H"
@ -193,14 +192,13 @@ public:
bool newFormat = true
);
//- Construct and return a clone
//- Return a clone
virtual autoPtr<particle> clone() const
{
return autoPtr<particle>(new DSMCParcel<ParcelType>(*this));
return particle::Clone(*this);
}
//- Factory class to read-construct particles used for
// parallel transfer
//- Factory class to read-construct particles (for parallel transfer)
class iNew
{
const polyMesh& mesh_;

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2017 OpenFOAM Foundation
Copyright (C) 2019 OpenCFD Ltd.
Copyright (C) 2019-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -40,7 +40,6 @@ SourceFiles
#include "particle.H"
#include "IOstream.H"
#include "autoPtr.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
@ -109,13 +108,14 @@ public:
//- Construct as a copy
indexedParticle(const indexedParticle& p)
:
particle(p)
particle(p),
index_(p.index_)
{}
//- Construct and return a clone
//- Return a clone
virtual autoPtr<particle> clone() const
{
return autoPtr<particle>(new indexedParticle(*this));
return particle::Clone(*this);
}

View File

@ -5,7 +5,7 @@
\\ / A nd | www.openfoam.com
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2016-2019 OpenCFD Ltd.
Copyright (C) 2016-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -46,7 +46,6 @@ SeeAlso
#include "particle.H"
#include "IOstream.H"
#include "autoPtr.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
@ -147,20 +146,19 @@ public:
//- Construct as a copy
injectedParticle(const injectedParticle& p, const polyMesh& mesh);
//- Construct and return a (basic particle) clone
//- Return a (basic particle) clone
virtual autoPtr<particle> clone() const
{
return autoPtr<particle>(new injectedParticle(*this));
return particle::Clone(*this);
}
//- Construct and return a (basic particle) clone
virtual autoPtr<particle> clone(const polyMesh& mesh) const
{
return autoPtr<particle>(new injectedParticle(*this, mesh));
return particle::Clone(*this, mesh);
}
//- Factory class to read-construct particles used for
// parallel transfer
//- Factory class to read-construct particles (for parallel transfer)
class iNew
{
const polyMesh& mesh_;
@ -174,10 +172,7 @@ public:
autoPtr<injectedParticle> operator()(Istream& is) const
{
return autoPtr<injectedParticle>
(
new injectedParticle(mesh_, is, true)
);
return autoPtr<injectedParticle>::New(mesh_, is, true);
}
};

View File

@ -599,22 +599,6 @@ Foam::particle::particle
}
Foam::particle::particle(const particle& p)
:
mesh_(p.mesh_),
coordinates_(p.coordinates_),
celli_(p.celli_),
tetFacei_(p.tetFacei_),
tetPti_(p.tetPti_),
facei_(p.facei_),
stepFraction_(p.stepFraction_),
behind_(p.behind_),
nBehind_(p.nBehind_),
origProc_(p.origProc_),
origId_(p.origId_)
{}
Foam::particle::particle(const particle& p, const polyMesh& mesh)
:
mesh_(mesh),
@ -631,6 +615,12 @@ Foam::particle::particle(const particle& p, const polyMesh& mesh)
{}
Foam::particle::particle(const particle& p)
:
particle(p, p.mesh())
{}
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
Foam::scalar Foam::particle::track

View File

@ -417,18 +417,35 @@ public:
const bool doLocate = true
);
//- Construct as a copy
particle(const particle& p);
//- Construct as a copy with reference to a new mesh
//- Construct as a copy with reference to a mesh
particle(const particle& p, const polyMesh& mesh);
//- Copy construct
particle(const particle& p);
//- Construct a clone
virtual autoPtr<particle> clone() const
{
return autoPtr<particle>::New(*this);
}
// Factory Methods
//- Clone a particle
template<class Derived>
static autoPtr<particle> Clone(const Derived& p)
{
return autoPtr<particle>(new Derived(p));
}
//- Clone a particle with a mesh reference
template<class Derived>
static autoPtr<particle> Clone(const Derived& p, const polyMesh& mesh)
{
return autoPtr<particle>(new Derived(p, mesh));
}
//- Factory class to read-construct particles (for parallel transfer)
class iNew
{

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2017 OpenFOAM Foundation
Copyright (C) 2019 OpenCFD Ltd.
Copyright (C) 2019-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -40,7 +40,6 @@ SourceFiles
#include "particle.H"
#include "IOstream.H"
#include "autoPtr.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
@ -106,10 +105,10 @@ public:
{}
//- Construct and return a clone
//- Return a clone
virtual autoPtr<particle> clone() const
{
return autoPtr<particle>(new passiveParticle(*this));
return particle::Clone(*this);
}

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2017 OpenFOAM Foundation
Copyright (C) 2016-2019 OpenCFD Ltd.
Copyright (C) 2016-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -226,20 +226,19 @@ public:
//- Construct as a copy
CollidingParcel(const CollidingParcel& p, const polyMesh& mesh);
//- Construct and return a (basic particle) clone
//- Return a (basic particle) clone
virtual autoPtr<particle> clone() const
{
return autoPtr<particle>(new CollidingParcel(*this));
return particle::Clone(*this);
}
//- Construct and return a (basic particle) clone
//- Return a (basic particle) clone
virtual autoPtr<particle> clone(const polyMesh& mesh) const
{
return autoPtr<particle>(new CollidingParcel(*this, mesh));
return particle::Clone(*this, mesh);
}
//- Factory class to read-construct particles used for
// parallel transfer
//- Factory class to read-construct particles (for parallel transfer)
class iNew
{
const polyMesh& mesh_;

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2017 OpenFOAM Foundation
Copyright (C) 2016-2021 OpenCFD Ltd.
Copyright (C) 2016-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -52,7 +52,6 @@ SourceFiles
#include "particle.H"
#include "IOstream.H"
#include "autoPtr.H"
#include "interpolation.H"
#include "demandDrivenEntry.H"
#include "labelFieldIOField.H"
@ -433,20 +432,19 @@ public:
//- Construct as a copy
KinematicParcel(const KinematicParcel& p, const polyMesh& mesh);
//- Construct and return a (basic particle) clone
//- Return a (basic particle) clone
virtual autoPtr<particle> clone() const
{
return autoPtr<particle>(new KinematicParcel(*this));
return particle::Clone(*this);
}
//- Construct and return a (basic particle) clone
//- Return a (basic particle) clone
virtual autoPtr<particle> clone(const polyMesh& mesh) const
{
return autoPtr<particle>(new KinematicParcel(*this, mesh));
return particle::Clone(*this, mesh);
}
//- Factory class to read-construct particles used for
// parallel transfer
//- Factory class to read-construct particles (for parallel transfer)
class iNew
{
const polyMesh& mesh_;

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2013-2017 OpenFOAM Foundation
Copyright (C) 2016-2019 OpenCFD Ltd.
Copyright (C) 2016-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -238,20 +238,19 @@ public:
//- Construct as a copy
MPPICParcel(const MPPICParcel& p, const polyMesh& mesh);
//- Construct and return a (basic particle) clone
//- Return a (basic particle) clone
virtual autoPtr<particle> clone() const
{
return autoPtr<particle>(new MPPICParcel(*this));
return particle::Clone(*this);
}
//- Construct and return a (basic particle) clone
//- Return a (basic particle) clone
virtual autoPtr<particle> clone(const polyMesh& mesh) const
{
return autoPtr<particle>(new MPPICParcel(*this, mesh));
return particle::Clone(*this, mesh);
}
//- Factory class to read-construct particles used for
// parallel transfer
//- Factory class to read-construct particles (for parallel transfer)
class iNew
{
const polyMesh& mesh_;

View File

@ -5,7 +5,7 @@
\\ / A nd | www.openfoam.com
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2018-2019 OpenCFD Ltd.
Copyright (C) 2018-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -280,23 +280,19 @@ public:
const polyMesh& mesh
);
//- Construct and return a (basic particle) clone
//- Return a (basic particle) clone
virtual autoPtr<particle> clone() const
{
return autoPtr<particle>(new ReactingHeterogeneousParcel(*this));
return particle::Clone(*this);
}
//- Construct and return a (basic particle) clone
//- Return a (basic particle) clone
virtual autoPtr<particle> clone(const polyMesh& mesh) const
{
return autoPtr<particle>
(
new ReactingHeterogeneousParcel(*this, mesh)
);
return particle::Clone(*this, mesh);
}
//- Factory class to read-construct particles used for
// parallel transfer
//- Factory class to read-construct particles (for parallel transfer)
class iNew
{
const polyMesh& mesh_;

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2017 OpenFOAM Foundation
Copyright (C) 2016-2019 OpenCFD Ltd.
Copyright (C) 2016-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -357,20 +357,19 @@ public:
const polyMesh& mesh
);
//- Construct and return a (basic particle) clone
//- Return a (basic particle) clone
virtual autoPtr<particle> clone() const
{
return autoPtr<particle>(new ReactingMultiphaseParcel(*this));
return particle::Clone(*this);
}
//- Construct and return a (basic particle) clone
//- Return a (basic particle) clone
virtual autoPtr<particle> clone(const polyMesh& mesh) const
{
return autoPtr<particle>(new ReactingMultiphaseParcel(*this, mesh));
return particle::Clone(*this, mesh);
}
//- Factory class to read-construct particles used for
// parallel transfer
//- Factory class to read-construct particles (for parallel transfer)
class iNew
{
const polyMesh& mesh_;

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2017 OpenFOAM Foundation
Copyright (C) 2016-2020 OpenCFD Ltd.
Copyright (C) 2016-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -327,23 +327,19 @@ public:
//- Construct as a copy
ReactingParcel(const ReactingParcel& p);
//- Construct and return a (basic particle) clone
//- Return a (basic particle) clone
virtual autoPtr<particle> clone() const
{
return autoPtr<particle>(new ReactingParcel<ParcelType>(*this));
return particle::Clone(*this);
}
//- Construct and return a (basic particle) clone
//- Return a (basic particle) clone
virtual autoPtr<particle> clone(const polyMesh& mesh) const
{
return autoPtr<particle>
(
new ReactingParcel<ParcelType>(*this, mesh)
);
return particle::Clone(*this, mesh);
}
//- Factory class to read-construct particles used for
// parallel transfer
//- Factory class to read-construct particles (for parallel transfer)
class iNew
{
const polyMesh& mesh_;

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2017 OpenFOAM Foundation
Copyright (C) 2016-2019 OpenCFD Ltd.
Copyright (C) 2016-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -348,20 +348,19 @@ public:
//- Construct as a copy
ThermoParcel(const ThermoParcel& p, const polyMesh& mesh);
//- Construct and return a (basic particle) clone
//- Return a (basic particle) clone
virtual autoPtr<particle> clone() const
{
return autoPtr<particle>(new ThermoParcel(*this));
return particle::Clone(*this);
}
//- Construct and return a (basic particle) clone
//- Return a (basic particle) clone
virtual autoPtr<particle> clone(const polyMesh& mesh) const
{
return autoPtr<particle>(new ThermoParcel(*this, mesh));
return particle::Clone(*this, mesh);
}
//- Factory class to read-construct particles used for
// parallel transfer
//- Factory class to read-construct particles (for parallel transfer)
class iNew
{
const polyMesh& mesh_;

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2017 OpenFOAM Foundation
Copyright (C) 2016 OpenCFD Ltd.
Copyright (C) 2016-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -42,7 +42,6 @@ SourceFiles
#include "particle.H"
#include "IOstream.H"
#include "autoPtr.H"
#include "diagTensor.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
@ -283,14 +282,13 @@ public:
bool newFormat = true
);
//- Construct and return a clone
autoPtr<particle> clone() const
//- Return a clone
virtual autoPtr<particle> clone() const
{
return autoPtr<particle>(new molecule(*this));
return particle::Clone(*this);
}
//- Factory class to read-construct particles used for
// parallel transfer
//- Factory class to read-construct particles (for parallel transfer)
class iNew
{
const polyMesh& mesh_;

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2017 OpenFOAM Foundation
Copyright (C) 2016-2019 OpenCFD Ltd.
Copyright (C) 2016-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -43,7 +43,6 @@ SourceFiles
#include "particle.H"
#include "IOstream.H"
#include "autoPtr.H"
#include "interpolationCellPoint.H"
#include "contiguous.H"
@ -185,10 +184,10 @@ public:
bool newFormat = true
);
//- Construct and return a clone
//- Return a clone
virtual autoPtr<particle> clone() const
{
return autoPtr<particle>(new solidParticle(*this));
return particle::Clone(*this);
}
//- Factory class to read-construct particles (for parallel transfer)

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2017 OpenFOAM Foundation
Copyright (C) 2016-2019 OpenCFD Ltd.
Copyright (C) 2016-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -275,23 +275,19 @@ public:
//- Construct as a copy
SprayParcel(const SprayParcel& p);
//- Construct and return a (basic particle) clone
//- Return a (basic particle) clone
virtual autoPtr<particle> clone() const
{
return autoPtr<particle>(new SprayParcel<ParcelType>(*this));
return particle::Clone(*this);
}
//- Construct and return a (basic particle) clone
//- Return a (basic particle) clone
virtual autoPtr<particle> clone(const polyMesh& mesh) const
{
return autoPtr<particle>
(
new SprayParcel<ParcelType>(*this, mesh)
);
return particle::Clone(*this, mesh);
}
//- Factory class to read-construct particles used for
// parallel transfer
//- Factory class to read-construct particles (for parallel transfer)
class iNew
{
const polyMesh& mesh_;

View File

@ -6,7 +6,7 @@
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2011-2017 OpenFOAM Foundation
Copyright (C) 2017-2019 OpenCFD Ltd.
Copyright (C) 2017-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -41,7 +41,6 @@ SourceFiles
#include "bitSet.H"
#include "particle.H"
#include "autoPtr.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
@ -164,14 +163,13 @@ public:
bool newFormat = true
);
//- Construct and return a clone
autoPtr<particle> clone() const
//- Return a clone
virtual autoPtr<particle> clone() const
{
return autoPtr<particle>::NewFrom<trackedParticle>(*this);
return particle::Clone(*this);
}
//- Factory class to read-construct particles used for
// parallel transfer
//- Factory class to read-construct particles (for parallel transfer)
class iNew
{
const polyMesh& mesh_;

View File

@ -165,16 +165,6 @@ Foam::PatchFunction1Types::CodedField<Type>::CodedField
}
template<class Type>
Foam::PatchFunction1Types::CodedField<Type>::CodedField
(
const CodedField<Type>& rhs
)
:
CodedField<Type>(rhs, rhs.patch())
{}
template<class Type>
Foam::PatchFunction1Types::CodedField<Type>::CodedField
(
@ -189,6 +179,16 @@ Foam::PatchFunction1Types::CodedField<Type>::CodedField
{}
template<class Type>
Foam::PatchFunction1Types::CodedField<Type>::CodedField
(
const CodedField<Type>& rhs
)
:
CodedField<Type>(rhs, rhs.patch())
{}
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
template<class Type>

View File

@ -5,7 +5,7 @@
\\ / A nd | www.openfoam.com
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2020-2021 OpenCFD Ltd.
Copyright (C) 2020-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -181,9 +181,6 @@ public:
const bool faceValues = true
);
//- Copy construct
explicit CodedField(const CodedField<Type>& rhs);
//- Copy construct, setting patch
explicit CodedField
(
@ -191,22 +188,19 @@ public:
const polyPatch& pp
);
//- Construct and return a clone
//- Copy construct
explicit CodedField(const CodedField<Type>& rhs);
//- Return a clone
virtual tmp<PatchFunction1<Type>> clone() const
{
return tmp<PatchFunction1<Type>>
(
new CodedField<Type>(*this)
);
return PatchFunction1<Type>::Clone(*this);
}
//- Construct and return a clone setting patch
//- Return a clone, setting the patch
virtual tmp<PatchFunction1<Type>> clone(const polyPatch& pp) const
{
return tmp<PatchFunction1<Type>>
(
new CodedField<Type>(*this, pp)
);
return PatchFunction1<Type>::Clone(*this, pp);
}

View File

@ -248,16 +248,6 @@ Foam::PatchFunction1Types::ConstantField<Type>::ConstantField
{}
template<class Type>
Foam::PatchFunction1Types::ConstantField<Type>::ConstantField
(
const ConstantField<Type>& rhs
)
:
ConstantField<Type>(rhs, rhs.patch())
{}
template<class Type>
Foam::PatchFunction1Types::ConstantField<Type>::ConstantField
(
@ -280,6 +270,16 @@ Foam::PatchFunction1Types::ConstantField<Type>::ConstantField
}
template<class Type>
Foam::PatchFunction1Types::ConstantField<Type>::ConstantField
(
const ConstantField<Type>& rhs
)
:
ConstantField<Type>(rhs, rhs.patch())
{}
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
template<class Type>

View File

@ -5,7 +5,7 @@
\\ / A nd | www.openfoam.com
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2018-2022 OpenCFD Ltd.
Copyright (C) 2018-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -147,9 +147,6 @@ public:
const bool faceValues = true
);
//- Copy construct
explicit ConstantField(const ConstantField<Type>& rhs);
//- Copy construct setting patch
explicit ConstantField
(
@ -157,19 +154,19 @@ public:
const polyPatch& pp
);
//- Construct and return a clone
//- Copy construct
explicit ConstantField(const ConstantField<Type>& rhs);
//- Return a clone
virtual tmp<PatchFunction1<Type>> clone() const
{
return tmp<PatchFunction1<Type>>(new ConstantField<Type>(*this));
return PatchFunction1<Type>::Clone(*this);
}
//- Construct and return a clone setting patch
//- Return a clone, setting the patch
virtual tmp<PatchFunction1<Type>> clone(const polyPatch& pp) const
{
return tmp<PatchFunction1<Type>>
(
new ConstantField<Type>(*this, pp)
);
return PatchFunction1<Type>::Clone(*this, pp);
}

View File

@ -167,16 +167,6 @@ Foam::PatchFunction1Types::MappedFile<Type>::MappedFile
{}
template<class Type>
Foam::PatchFunction1Types::MappedFile<Type>::MappedFile
(
const MappedFile<Type>& rhs
)
:
MappedFile<Type>(rhs, rhs.patch())
{}
template<class Type>
Foam::PatchFunction1Types::MappedFile<Type>::MappedFile
(
@ -214,6 +204,16 @@ Foam::PatchFunction1Types::MappedFile<Type>::MappedFile
}
template<class Type>
Foam::PatchFunction1Types::MappedFile<Type>::MappedFile
(
const MappedFile<Type>& rhs
)
:
MappedFile<Type>(rhs, rhs.patch())
{}
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
template<class Type>

View File

@ -5,7 +5,7 @@
\\ / A nd | www.openfoam.com
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2018-2022 OpenCFD Ltd.
Copyright (C) 2018-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -219,9 +219,6 @@ public:
const bool faceValues = true
);
//- Copy construct
explicit MappedFile(const MappedFile<Type>& rhs);
//- Copy construct setting patch
explicit MappedFile
(
@ -229,22 +226,19 @@ public:
const polyPatch& pp
);
//- Construct and return a clone
//- Copy construct
explicit MappedFile(const MappedFile<Type>& rhs);
//- Return a clone
virtual tmp<PatchFunction1<Type>> clone() const
{
return tmp<PatchFunction1<Type>>
(
new MappedFile<Type>(*this)
);
return PatchFunction1<Type>::Clone(*this, this->patch());
}
//- Construct and return a clone setting patch
//- Return a clone, setting the patch
virtual tmp<PatchFunction1<Type>> clone(const polyPatch& pp) const
{
return tmp<PatchFunction1<Type>>
(
new MappedFile<Type>(*this, pp)
);
return PatchFunction1<Type>::Clone(*this, pp);
}

View File

@ -58,13 +58,6 @@ Foam::PatchFunction1<Type>::PatchFunction1
{}
template<class Type>
Foam::PatchFunction1<Type>::PatchFunction1(const PatchFunction1<Type>& rhs)
:
PatchFunction1<Type>(rhs, rhs.patch())
{}
template<class Type>
Foam::PatchFunction1<Type>::PatchFunction1
(
@ -77,6 +70,13 @@ Foam::PatchFunction1<Type>::PatchFunction1
{}
template<class Type>
Foam::PatchFunction1<Type>::PatchFunction1(const PatchFunction1<Type>& rhs)
:
PatchFunction1<Type>(rhs, rhs.patch())
{}
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
template<class Type>

View File

@ -5,7 +5,7 @@
\\ / A nd | www.openfoam.com
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2018-2022 OpenCFD Ltd.
Copyright (C) 2018-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -147,9 +147,6 @@ public:
const bool faceValues = true
);
//- Copy construct
explicit PatchFunction1(const PatchFunction1<Type>& rhs);
//- Copy construct setting patch
explicit PatchFunction1
(
@ -157,6 +154,9 @@ public:
const polyPatch& pp
);
//- Copy construct
explicit PatchFunction1(const PatchFunction1<Type>& rhs);
//- Return a clone
virtual tmp<PatchFunction1<Type>> clone() const = 0;
@ -164,7 +164,24 @@ public:
virtual tmp<PatchFunction1<Type>> clone(const polyPatch& pp) const = 0;
// Selectors
// Factory Methods
//- Clone a PatchFunction1
template<class Derived>
static tmp<PatchFunction1<Type>>
Clone(const Derived& fun)
{
return tmp<PatchFunction1<Type>>(new Derived(fun));
}
//- Clone a PatchFunction1 with a patch
template<class Derived>
static tmp<PatchFunction1<Type>>
Clone(const Derived& fun, const polyPatch& pp)
{
return tmp<PatchFunction1<Type>>(new Derived(fun, pp));
}
//- Selector
static autoPtr<PatchFunction1<Type>> New

View File

@ -54,16 +54,6 @@ Foam::PatchFunction1Types::UniformValueField<Type>::UniformValueField
{}
template<class Type>
Foam::PatchFunction1Types::UniformValueField<Type>::UniformValueField
(
const UniformValueField<Type>& rhs
)
:
UniformValueField<Type>(rhs, rhs.patch())
{}
template<class Type>
Foam::PatchFunction1Types::UniformValueField<Type>::UniformValueField
(
@ -81,6 +71,16 @@ Foam::PatchFunction1Types::UniformValueField<Type>::UniformValueField
}
template<class Type>
Foam::PatchFunction1Types::UniformValueField<Type>::UniformValueField
(
const UniformValueField<Type>& rhs
)
:
UniformValueField<Type>(rhs, rhs.patch())
{}
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
template<class Type>

View File

@ -5,7 +5,7 @@
\\ / A nd | www.openfoam.com
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2018-2021 OpenCFD Ltd.
Copyright (C) 2018-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -40,8 +40,8 @@ SourceFiles
\*---------------------------------------------------------------------------*/
#ifndef PatchFunction1Types_UniformValueField_H
#define PatchFunction1Types_UniformValueField_H
#ifndef Foam_PatchFunction1Types_UniformValueField_H
#define Foam_PatchFunction1Types_UniformValueField_H
#include "PatchFunction1.H"
#include "Function1.H"
@ -92,9 +92,6 @@ public:
const bool faceValues = true
);
//- Copy construct
explicit UniformValueField(const UniformValueField<Type>& rhs);
//- Copy construct setting patch
explicit UniformValueField
(
@ -102,22 +99,19 @@ public:
const polyPatch& pp
);
//- Construct and return a clone
//- Copy construct
explicit UniformValueField(const UniformValueField<Type>& rhs);
//- Return a clone
virtual tmp<PatchFunction1<Type>> clone() const
{
return tmp<PatchFunction1<Type>>
(
new UniformValueField<Type>(*this)
);
return PatchFunction1<Type>::Clone(*this);
}
//- Construct and return a clone setting patch
//- Return a clone, setting the patch
virtual tmp<PatchFunction1<Type>> clone(const polyPatch& pp) const
{
return tmp<PatchFunction1<Type>>
(
new UniformValueField<Type>(*this, pp)
);
return PatchFunction1<Type>::Clone(*this, pp);
}

View File

@ -89,7 +89,7 @@ Foam::fvFieldDecomposer::decomposeField
(
fvPatchFieldBase::calculatedType(),
procMesh_.boundary()[patchi],
DimensionedField<Type, volMesh>::null()
fvPatchField<Type>::Internal::null()
)
);
}
@ -262,7 +262,7 @@ Foam::fvFieldDecomposer::decomposeField
(
fvsPatchFieldBase::calculatedType(),
procMesh_.boundary()[patchi],
DimensionedField<Type, surfaceMesh>::null()
fvsPatchField<Type>::Internal::null()
)
);
}

View File

@ -56,7 +56,7 @@ Foam::pointFieldDecomposer::decomposeField
(
field.boundaryField()[boundaryAddressing_[patchi]],
procMesh_.boundary()[patchi],
DimensionedField<Type, pointMesh>::null(),
pointPatchField<Type>::Internal::null(),
patchFieldDecomposerPtrs_[patchi]
)
);
@ -69,7 +69,7 @@ Foam::pointFieldDecomposer::decomposeField
new processorPointPatchField<Type>
(
procMesh_.boundary()[patchi],
DimensionedField<Type, pointMesh>::null()
pointPatchField<Type>::Internal::null()
)
);
}

View File

@ -60,7 +60,7 @@ Foam::faFieldDecomposer::decomposeField
(
field.boundaryField()[oldPatchi],
procMesh_.boundary()[patchi],
DimensionedField<Type, areaMesh>::null(),
faPatchField<Type>::Internal::null(),
patchFieldDecomposerPtrs_[patchi]
)
);
@ -73,7 +73,7 @@ Foam::faFieldDecomposer::decomposeField
new processorFaPatchField<Type>
(
procMesh_.boundary()[patchi],
DimensionedField<Type, areaMesh>::null(),
faPatchField<Type>::Internal::null(),
Field<Type>
(
field.internalField(),
@ -171,7 +171,7 @@ Foam::faFieldDecomposer::decomposeField
(
field.boundaryField()[oldPatchi],
procMesh_.boundary()[patchi],
DimensionedField<Type, edgeMesh>::null(),
faePatchField<Type>::Internal::null(),
patchFieldDecomposerPtrs_[patchi]
)
);
@ -184,7 +184,7 @@ Foam::faFieldDecomposer::decomposeField
new processorFaePatchField<Type>
(
procMesh_.boundary()[patchi],
DimensionedField<Type, edgeMesh>::null(),
faePatchField<Type>::Internal::null(),
Field<Type>
(
allEdgeField,

View File

@ -29,10 +29,9 @@ License
#include "faFieldReconstructor.H"
#include "Time.H"
#include "PtrList.H"
#include "faPatchFields.H"
#include "emptyFaPatch.H"
#include "emptyFaPatchField.H"
#include "emptyFaePatchField.H"
#include "faPatchFields.H"
#include "faePatchFields.H"
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
@ -130,7 +129,7 @@ Foam::faFieldReconstructor::reconstructField
(
procField.boundaryField()[patchI],
mesh_.boundary()[curBPatch],
DimensionedField<Type, areaMesh>::null(),
faPatchField<Type>::Internal::null(),
faPatchFieldReconstructor
(
mesh_.boundary()[curBPatch].size(),
@ -204,7 +203,7 @@ Foam::faFieldReconstructor::reconstructField
(
mesh_.boundary()[curBPatch].type(),
mesh_.boundary()[curBPatch],
DimensionedField<Type, areaMesh>::null()
faPatchField<Type>::Internal::null()
)
);
}
@ -238,9 +237,9 @@ Foam::faFieldReconstructor::reconstructField
patchI,
faPatchField<Type>::New
(
emptyFaPatchField<Type>::typeName,
faPatchFieldBase::emptyType(),
mesh_.boundary()[patchI],
DimensionedField<Type, areaMesh>::null()
faPatchField<Type>::Internal::null()
)
);
}
@ -371,7 +370,7 @@ Foam::faFieldReconstructor::reconstructField
(
procField.boundaryField()[patchI],
mesh_.boundary()[curBPatch],
DimensionedField<Type, edgeMesh>::null(),
faePatchField<Type>::Internal::null(),
faPatchFieldReconstructor
(
mesh_.boundary()[curBPatch].size(),
@ -448,8 +447,7 @@ Foam::faFieldReconstructor::reconstructField
(
mesh_.boundary()[curBPatch].type(),
mesh_.boundary()[curBPatch],
DimensionedField<Type, edgeMesh>
::null()
faePatchField<Type>::Internal::null()
)
);
}
@ -489,9 +487,9 @@ Foam::faFieldReconstructor::reconstructField
patchI,
faePatchField<Type>::New
(
emptyFaePatchField<Type>::typeName,
faePatchFieldBase::emptyType(),
mesh_.boundary()[patchI],
DimensionedField<Type, edgeMesh>::null()
faePatchField<Type>::Internal::null()
)
);
}

View File

@ -29,10 +29,9 @@ License
#include "fvFieldReconstructor.H"
#include "Time.H"
#include "PtrList.H"
#include "fvPatchFields.H"
#include "emptyFvPatch.H"
#include "emptyFvPatchField.H"
#include "emptyFvsPatchField.H"
#include "fvPatchFields.H"
#include "fvsPatchFields.H"
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
@ -125,7 +124,7 @@ Foam::fvFieldReconstructor::reconstructField
(
procField.boundaryField()[patchi],
mesh_.boundary()[curBPatch],
DimensionedField<Type, volMesh>::null(),
fvPatchField<Type>::Internal::null(),
fvPatchFieldReconstructor
(
mesh_.boundary()[curBPatch].size()
@ -193,7 +192,7 @@ Foam::fvFieldReconstructor::reconstructField
(
mesh_.boundary()[curBPatch].type(),
mesh_.boundary()[curBPatch],
DimensionedField<Type, volMesh>::null()
fvPatchField<Type>::Internal::null()
)
);
}
@ -225,9 +224,9 @@ Foam::fvFieldReconstructor::reconstructField
patchi,
fvPatchField<Type>::New
(
emptyFvPatchField<Type>::typeName,
fvPatchFieldBase::emptyType(),
mesh_.boundary()[patchi],
DimensionedField<Type, volMesh>::null()
fvPatchField<Type>::Internal::null()
)
);
}
@ -323,7 +322,7 @@ Foam::fvFieldReconstructor::reconstructField
(
procField.boundaryField()[patchi],
mesh_.boundary()[curBPatch],
DimensionedField<Type, surfaceMesh>::null(),
fvsPatchField<Type>::Internal::null(),
fvPatchFieldReconstructor
(
mesh_.boundary()[curBPatch].size()
@ -379,8 +378,7 @@ Foam::fvFieldReconstructor::reconstructField
(
mesh_.boundary()[curBPatch].type(),
mesh_.boundary()[curBPatch],
DimensionedField<Type, surfaceMesh>
::null()
fvsPatchField<Type>::Internal::null()
)
);
}
@ -418,9 +416,9 @@ Foam::fvFieldReconstructor::reconstructField
patchi,
fvsPatchField<Type>::New
(
emptyFvsPatchField<Type>::typeName,
fvsPatchFieldBase::emptyType(),
mesh_.boundary()[patchi],
DimensionedField<Type, surfaceMesh>::null()
fvsPatchField<Type>::Internal::null()
)
);
}

View File

@ -5,7 +5,7 @@
\\ / A nd | www.openfoam.com
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2021-2022 OpenCFD Ltd.
Copyright (C) 2021-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -43,7 +43,6 @@ SourceFiles
#include "particle.H"
#include "IOstream.H"
#include "autoPtr.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
@ -131,17 +130,17 @@ public:
//- Construct as copy
passivePositionParticle(const passivePositionParticle& p)
:
particle(p)
particle(p),
location_(p.location_)
{}
//- Construct and return a clone
//- Return a clone
virtual autoPtr<particle> clone() const
{
return autoPtr<particle>(new passivePositionParticle(*this));
return particle::Clone(*this);
}
//- Factory class to read-construct particles (for parallel transfer)
class iNew
{

View File

@ -79,7 +79,7 @@ Foam::pointFieldReconstructor::reconstructField
(
procField.boundaryField()[patchi],
mesh_.boundary()[curBPatch],
DimensionedField<Type, pointMesh>::null(),
pointPatchField<Type>::Internal::null(),
pointPatchFieldReconstructor
(
mesh_.boundary()[curBPatch].size()

View File

@ -5,7 +5,7 @@
\\ / A nd | www.openfoam.com
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2021 OpenCFD Ltd.
Copyright (C) 2021-2024 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
@ -45,8 +45,8 @@ SourceFiles
\*---------------------------------------------------------------------------*/
#ifndef Function1Types_Sample_H
#define Function1Types_Sample_H
#ifndef Foam_Function1Types_Sample_H
#define Foam_Function1Types_Sample_H
#include "Function1.H"
#include "point.H"
@ -121,10 +121,10 @@ public:
//- Copy constructor
explicit Sample(const Sample& poly);
//- Construct and return a clone
//- Return a clone
virtual tmp<Function1<Type>> clone() const
{
return tmp<Function1<Type>>(new Sample<Type>(*this));
return Function1<Type>::Clone(*this);
}

View File

@ -612,7 +612,7 @@ Foam::meshToMesh::mapSrcToTgt
(
srcBfld[srcPatchi],
tgtMesh.boundary()[tgtPatchi],
DimensionedField<Type, volMesh>::null(),
fvPatchField<Type>::Internal::null(),
directFvPatchFieldMapper
(
labelList(tgtMesh.boundary()[tgtPatchi].size(), -1)
@ -636,7 +636,7 @@ Foam::meshToMesh::mapSrcToTgt
(
fvPatchFieldBase::calculatedType(),
tgtMesh.boundary()[tgtPatchi],
DimensionedField<Type, volMesh>::null()
fvPatchField<Type>::Internal::null()
)
);
}
@ -843,7 +843,7 @@ Foam::meshToMesh::mapTgtToSrc
(
tgtBfld[tgtPatchi],
srcMesh.boundary()[srcPatchi],
DimensionedField<Type, volMesh>::null(),
fvPatchField<Type>::Internal::null(),
directFvPatchFieldMapper
(
labelList(srcMesh.boundary()[srcPatchi].size(), -1)
@ -867,7 +867,7 @@ Foam::meshToMesh::mapTgtToSrc
(
fvPatchFieldBase::calculatedType(),
srcMesh.boundary()[srcPatchi],
DimensionedField<Type, volMesh>::null()
fvPatchField<Type>::Internal::null()
)
);
}

View File

@ -395,7 +395,7 @@ Foam::meshToMesh0::interpolate
(
fromVf.boundaryField()[patchi],
toMesh_.boundary()[patchi],
DimensionedField<Type, volMesh>::null(),
fvPatchField<Type>::Internal::null(),
patchFieldInterpolator
(
boundaryAddressing_[patchi]

View File

@ -114,10 +114,10 @@ public:
//- Construct from dictionary
Ar(const dictionary& dict);
//- Construct and return clone
//- Return a clone
virtual autoPtr<liquidProperties> clone() const
{
return autoPtr<liquidProperties>::NewFrom<Ar>(*this);
return liquidProperties::Clone(*this);
}

View File

@ -114,10 +114,10 @@ public:
//- Construct from dictionary
C10H22(const dictionary& dict);
//- Construct and return clone
//- Return a clone
virtual autoPtr<liquidProperties> clone() const
{
return autoPtr<liquidProperties>::NewFrom<C10H22>(*this);
return liquidProperties::Clone(*this);
}

View File

@ -114,10 +114,10 @@ public:
//- Construct from dictionary
C12H26(const dictionary& dict);
//- Construct and return clone
//- Return a clone
virtual autoPtr<liquidProperties> clone() const
{
return autoPtr<liquidProperties>::NewFrom<C12H26>(*this);
return liquidProperties::Clone(*this);
}

View File

@ -114,10 +114,10 @@ public:
//- Construct from dictionary
C13H28(const dictionary& dict);
//- Construct and return clone
//- Return a clone
virtual autoPtr<liquidProperties> clone() const
{
return autoPtr<liquidProperties>::NewFrom<C13H28>(*this);
return liquidProperties::Clone(*this);
}

View File

@ -114,10 +114,10 @@ public:
//- Construct from dictionary
C14H30(const dictionary& dict);
//- Construct and return clone
//- Return a clone
virtual autoPtr<liquidProperties> clone() const
{
return autoPtr<liquidProperties>::NewFrom<C14H30>(*this);
return liquidProperties::Clone(*this);
}

View File

@ -114,10 +114,10 @@ public:
//- Construct from dictionary
C16H34(const dictionary& dict);
//- Construct and return clone
//- Return a clone
virtual autoPtr<liquidProperties> clone() const
{
return autoPtr<liquidProperties>::NewFrom<C16H34>(*this);
return liquidProperties::Clone(*this);
}

View File

@ -114,10 +114,10 @@ public:
//- Construct from dictionary
C2H5OH(const dictionary& dict);
//- Construct and return clone
//- Return a clone
virtual autoPtr<liquidProperties> clone() const
{
return autoPtr<liquidProperties>::NewFrom<C2H5OH>(*this);
return liquidProperties::Clone(*this);
}

Some files were not shown because too many files have changed in this diff Show More