mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
added copy, and updated clone constructors
This commit is contained in:
@ -278,6 +278,16 @@ public:
|
||||
bool readFields = true
|
||||
);
|
||||
|
||||
//- Construct as a copy
|
||||
Particle(const Particle& p);
|
||||
|
||||
//- Construct a clone
|
||||
autoPtr<ParticleType> clone() const
|
||||
{
|
||||
return autoPtr<Particle>(new Particle(*this));
|
||||
}
|
||||
|
||||
|
||||
//- Factory class to read-construct particles used for
|
||||
// parallel transfer
|
||||
class iNew
|
||||
|
||||
@ -278,10 +278,13 @@ public:
|
||||
bool readFields = true
|
||||
);
|
||||
|
||||
//- Construct as a copy
|
||||
KinematicParcel(const KinematicParcel& p);
|
||||
|
||||
//- Construct and return a clone
|
||||
autoPtr<ParcelType> clone() const
|
||||
autoPtr<KinematicParcel> clone() const
|
||||
{
|
||||
return autoPtr<ParcelType>(new KinematicParcel<ParcelType>(*this));
|
||||
return autoPtr<KinematicParcel>(new KinematicParcel(*this));
|
||||
}
|
||||
|
||||
|
||||
|
||||
@ -295,13 +295,17 @@ public:
|
||||
bool readFields = true
|
||||
);
|
||||
|
||||
//- Construct as a copy
|
||||
ReactingMultiphaseParcel(const ReactingMultiphaseParcel& p);
|
||||
|
||||
//- Construct and return a clone
|
||||
autoPtr<ParcelType> clone() const
|
||||
autoPtr<ReactingMultiphaseParcel> clone() const
|
||||
{
|
||||
return autoPtr<ParcelType>
|
||||
(
|
||||
new ReactingMultiphaseParcel<ParcelType>(*this)
|
||||
);
|
||||
return
|
||||
autoPtr<ReactingMultiphaseParcel>
|
||||
(
|
||||
new ReactingMultiphaseParcel(*this)
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
|
||||
@ -244,10 +244,13 @@ public:
|
||||
bool readFields = true
|
||||
);
|
||||
|
||||
//- Construct as a copy
|
||||
ReactingParcel(const ReactingParcel& p);
|
||||
|
||||
//- Construct and return a clone
|
||||
autoPtr<ParcelType> clone() const
|
||||
autoPtr<ReactingParcel> clone() const
|
||||
{
|
||||
return autoPtr<ParcelType>(new ReactingParcel<ParcelType>(*this));
|
||||
return autoPtr<ReactingParcel>(new ReactingParcel(*this));
|
||||
}
|
||||
|
||||
|
||||
|
||||
@ -257,10 +257,13 @@ public:
|
||||
bool readFields = true
|
||||
);
|
||||
|
||||
//- Construct as a copy
|
||||
ThermoParcel(const ThermoParcel& p);
|
||||
|
||||
//- Construct and return a clone
|
||||
autoPtr<ParcelType> clone() const
|
||||
autoPtr<ThermoParcel> clone() const
|
||||
{
|
||||
return autoPtr<ParcelType>(new ThermoParcel<ParcelType>(*this));
|
||||
return autoPtr<ThermoParcel>(new ThermoParcel(*this));
|
||||
}
|
||||
|
||||
|
||||
|
||||
@ -75,6 +75,15 @@ Foam::basicKinematicParcel::basicKinematicParcel
|
||||
{}
|
||||
|
||||
|
||||
Foam::basicKinematicParcel::basicKinematicParcel
|
||||
(
|
||||
const basicKinematicParcel& p
|
||||
)
|
||||
:
|
||||
KinematicParcel<basicKinematicParcel>(p)
|
||||
{}
|
||||
|
||||
|
||||
// * * * * * * * * * * * * * * * * Destructors * * * * * * * * * * * * * * //
|
||||
|
||||
Foam::basicKinematicParcel::~basicKinematicParcel()
|
||||
|
||||
@ -81,11 +81,17 @@ public:
|
||||
bool readFields = true
|
||||
);
|
||||
|
||||
//- Construct as a copy
|
||||
basicKinematicParcel(const basicKinematicParcel& p);
|
||||
|
||||
//- Construct and return a clone
|
||||
autoPtr<basicKinematicParcel> clone() const
|
||||
{
|
||||
return autoPtr<basicKinematicParcel>
|
||||
(new basicKinematicParcel(*this));
|
||||
return
|
||||
autoPtr<basicKinematicParcel>
|
||||
(
|
||||
new basicKinematicParcel(*this)
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
|
||||
@ -88,6 +88,15 @@ Foam::basicReactingMultiphaseParcel::basicReactingMultiphaseParcel
|
||||
{}
|
||||
|
||||
|
||||
Foam::basicReactingMultiphaseParcel::basicReactingMultiphaseParcel
|
||||
(
|
||||
const basicReactingMultiphaseParcel& p
|
||||
)
|
||||
:
|
||||
ReactingMultiphaseParcel<basicReactingMultiphaseParcel>(p)
|
||||
{}
|
||||
|
||||
|
||||
// * * * * * * * * * * * * * * * * Destructors * * * * * * * * * * * * * * //
|
||||
|
||||
Foam::basicReactingMultiphaseParcel::~basicReactingMultiphaseParcel()
|
||||
|
||||
@ -85,11 +85,17 @@ public:
|
||||
bool readFields = true
|
||||
);
|
||||
|
||||
//- Construct as a copy
|
||||
basicReactingMultiphaseParcel(const basicReactingMultiphaseParcel& p);
|
||||
|
||||
//- Construct and return a clone
|
||||
autoPtr<basicReactingMultiphaseParcel> clone() const
|
||||
{
|
||||
return autoPtr<basicReactingMultiphaseParcel>
|
||||
(new basicReactingMultiphaseParcel(*this));
|
||||
return
|
||||
autoPtr<basicReactingMultiphaseParcel>
|
||||
(
|
||||
new basicReactingMultiphaseParcel(*this)
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
|
||||
@ -77,6 +77,15 @@ Foam::basicReactingParcel::basicReactingParcel
|
||||
{}
|
||||
|
||||
|
||||
Foam::basicReactingParcel::basicReactingParcel
|
||||
(
|
||||
const basicReactingParcel& p
|
||||
)
|
||||
:
|
||||
ReactingParcel<basicReactingParcel>(p)
|
||||
{}
|
||||
|
||||
|
||||
// * * * * * * * * * * * * * * * * Destructors * * * * * * * * * * * * * * //
|
||||
|
||||
Foam::basicReactingParcel::~basicReactingParcel()
|
||||
|
||||
@ -82,10 +82,17 @@ public:
|
||||
bool readFields = true
|
||||
);
|
||||
|
||||
//- Construct as a copy
|
||||
basicReactingParcel(const basicReactingParcel& p);
|
||||
|
||||
//- Construct and return a clone
|
||||
autoPtr<basicReactingParcel> clone() const
|
||||
{
|
||||
return autoPtr<basicReactingParcel>(new basicReactingParcel(*this));
|
||||
return
|
||||
autoPtr<basicReactingParcel>
|
||||
(
|
||||
new basicReactingParcel(*this)
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
|
||||
@ -75,6 +75,15 @@ Foam::basicThermoParcel::basicThermoParcel
|
||||
{}
|
||||
|
||||
|
||||
Foam::basicThermoParcel::basicThermoParcel
|
||||
(
|
||||
const basicThermoParcel& p
|
||||
)
|
||||
:
|
||||
ThermoParcel<basicThermoParcel>(p)
|
||||
{}
|
||||
|
||||
|
||||
// * * * * * * * * * * * * * * * * Destructors * * * * * * * * * * * * * * //
|
||||
|
||||
Foam::basicThermoParcel::~basicThermoParcel()
|
||||
|
||||
@ -80,10 +80,17 @@ public:
|
||||
bool readFields = true
|
||||
);
|
||||
|
||||
//- Construct as a copy
|
||||
basicThermoParcel(const basicThermoParcel& p);
|
||||
|
||||
//- Construct and return a clone
|
||||
autoPtr<basicThermoParcel> clone() const
|
||||
{
|
||||
return autoPtr<basicThermoParcel>(new basicThermoParcel(*this));
|
||||
return
|
||||
autoPtr<basicThermoParcel>
|
||||
(
|
||||
new basicThermoParcel(*this)
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user