Commit 5e4c5c94 authored by Mark Olesen's avatar Mark Olesen
Browse files

COMP: macros for non-templated boundary conditions

parent f729c75b
......@@ -501,80 +501,85 @@ const pointPatchField<Type>& operator+
#define makePointPatchTypeFieldTypeName(type) \
\
defineNamedTemplateTypeNameAndDebug(type, 0);
defineNamedTemplateTypeNameAndDebug(type, 0);
#define makePointPatchFieldsTypeName(type) \
\
makePointPatchTypeFieldTypeName(type##PointPatchScalarField); \
makePointPatchTypeFieldTypeName(type##PointPatchVectorField); \
makePointPatchTypeFieldTypeName(type##PointPatchSphericalTensorField); \
makePointPatchTypeFieldTypeName(type##PointPatchSymmTensorField); \
makePointPatchTypeFieldTypeName(type##PointPatchTensorField);
makePointPatchTypeFieldTypeName(type##PointPatchScalarField); \
makePointPatchTypeFieldTypeName(type##PointPatchVectorField); \
makePointPatchTypeFieldTypeName(type##PointPatchSphericalTensorField); \
makePointPatchTypeFieldTypeName(type##PointPatchSymmTensorField); \
makePointPatchTypeFieldTypeName(type##PointPatchTensorField);
#define makePointPatchTypeField(PatchTypeField, typePatchTypeField) \
\
defineNamedTemplateTypeNameAndDebug(typePatchTypeField, 0); \
\
addToRunTimeSelectionTable \
( \
PatchTypeField, typePatchTypeField, pointPatch \
); \
\
addToRunTimeSelectionTable \
( \
PatchTypeField, \
typePatchTypeField, \
patchMapper \
); \
#define addToPointPatchFieldRunTimeSelection(PatchTypeField, typePatchTypeField) \
\
addToRunTimeSelectionTable \
( \
PatchTypeField, typePatchTypeField, dictionary \
);
addToRunTimeSelectionTable \
( \
PatchTypeField, \
typePatchTypeField, \
pointPatch \
); \
addToRunTimeSelectionTable \
( \
PatchTypeField, \
typePatchTypeField, \
patchMapper \
); \
addToRunTimeSelectionTable \
( \
PatchTypeField, \
typePatchTypeField, \
dictionary \
);
// for non-templated patch fields
#define makeNonTemplatedPointPatchTypeField(PatchTypeField,typePatchTypeField)\
defineTypeNameAndDebug(typePatchTypeField, 0); \
addToPointPatchFieldRunTimeSelection(PatchTypeField, typePatchTypeField)
// for templated patch fields
#define makePointPatchTypeField(PatchTypeField, typePatchTypeField) \
defineNamedTemplateTypeNameAndDebug(typePatchTypeField, 0); \
addToPointPatchFieldRunTimeSelection(PatchTypeField, typePatchTypeField)
#define makePointPatchFields(type) \
\
makePointPatchTypeField \
( \
pointPatchScalarField, \
type##PointPatchScalarField \
); \
\
makePointPatchTypeField \
( \
pointPatchVectorField, \
type##PointPatchVectorField \
); \
\
makePointPatchTypeField \
( \
pointPatchSphericalTensorField, \
type##PointPatchSphericalTensorField \
); \
\
makePointPatchTypeField \
( \
pointPatchSymmTensorField, \
type##PointPatchSymmTensorField \
); \
\
makePointPatchTypeField \
( \
pointPatchTensorField, \
type##PointPatchTensorField \
makePointPatchTypeField \
( \
pointPatchScalarField, \
type##PointPatchScalarField \
); \
makePointPatchTypeField \
( \
pointPatchVectorField, \
type##PointPatchVectorField \
); \
makePointPatchTypeField \
( \
pointPatchSphericalTensorField, \
type##PointPatchSphericalTensorField \
); \
makePointPatchTypeField \
( \
pointPatchSymmTensorField, \
type##PointPatchSymmTensorField \
); \
makePointPatchTypeField \
( \
pointPatchTensorField, \
type##PointPatchTensorField \
);
#define makePointPatchFieldTypedefs(type) \
\
typedef type##PointPatchField<scalar> type##PointPatchScalarField; \
typedef type##PointPatchField<vector> type##PointPatchVectorField; \
typedef type##PointPatchField<sphericalTensor> \
type##PointPatchSphericalTensorField; \
typedef type##PointPatchField<symmTensor> type##PointPatchSymmTensorField; \
typedef type##PointPatchField<tensor> type##PointPatchTensorField;
typedef type##PointPatchField<scalar> type##PointPatchScalarField; \
typedef type##PointPatchField<vector> type##PointPatchVectorField; \
typedef type##PointPatchField<sphericalTensor> \
type##PointPatchSphericalTensorField; \
typedef type##PointPatchField<symmTensor> type##PointPatchSymmTensorField;\
typedef type##PointPatchField<tensor> type##PointPatchTensorField;
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
......
......@@ -164,7 +164,7 @@ void Foam::SRFVelocityFvPatchVectorField::write(Ostream& os) const
namespace Foam
{
makePatchTypeField
makeNonTemplatedPatchTypeField
(
fvPatchVectorField,
SRFVelocityFvPatchVectorField
......
......@@ -310,11 +310,12 @@ void Foam::activeBaffleVelocityFvPatchVectorField::write(Ostream& os) const
namespace Foam
{
makePatchTypeField
makeNonTemplatedPatchTypeField
(
fvPatchVectorField,
activeBaffleVelocityFvPatchVectorField
);
}
// ************************************************************************* //
......@@ -145,7 +145,7 @@ void Foam::buoyantPressureFvPatchScalarField::write(Ostream& os) const
namespace Foam
{
makePatchTypeField
makeNonTemplatedPatchTypeField
(
fvPatchScalarField,
buoyantPressureFvPatchScalarField
......
......@@ -162,7 +162,7 @@ void Foam::cylindricalInletVelocityFvPatchVectorField::write(Ostream& os) const
namespace Foam
{
makePatchTypeField
makeNonTemplatedPatchTypeField
(
fvPatchVectorField,
cylindricalInletVelocityFvPatchVectorField
......
......@@ -264,7 +264,7 @@ void Foam::directMappedVelocityFluxFixedValueFvPatchField::write
namespace Foam
{
makePatchTypeField
makeNonTemplatedPatchTypeField
(
fvPatchVectorField,
directMappedVelocityFluxFixedValueFvPatchField
......
......@@ -172,7 +172,7 @@ void Foam::fixedFluxPressureFvPatchScalarField::write(Ostream& os) const
namespace Foam
{
makePatchTypeField
makeNonTemplatedPatchTypeField
(
fvPatchScalarField,
fixedFluxPressureFvPatchScalarField
......
......@@ -137,7 +137,7 @@ void Foam::fixedPressureCompressibleDensityFvPatchScalarField::write
namespace Foam
{
makePatchTypeField
makeNonTemplatedPatchTypeField
(
fvPatchScalarField,
fixedPressureCompressibleDensityFvPatchScalarField
......
......@@ -168,7 +168,7 @@ void Foam::flowRateInletVelocityFvPatchVectorField::write(Ostream& os) const
namespace Foam
{
makePatchTypeField
makeNonTemplatedPatchTypeField
(
fvPatchVectorField,
flowRateInletVelocityFvPatchVectorField
......
......@@ -152,7 +152,7 @@ void Foam::fluxCorrectedVelocityFvPatchVectorField::write(Ostream& os) const
namespace Foam
{
makePatchTypeField
makeNonTemplatedPatchTypeField
(
fvPatchVectorField,
fluxCorrectedVelocityFvPatchVectorField
......
......@@ -144,7 +144,7 @@ void Foam::freestreamPressureFvPatchScalarField::updateCoeffs()
namespace Foam
{
makePatchTypeField
makeNonTemplatedPatchTypeField
(
fvPatchScalarField,
freestreamPressureFvPatchScalarField
......
......@@ -203,7 +203,7 @@ const
namespace Foam
{
makePatchTypeField
makeNonTemplatedPatchTypeField
(
fvPatchScalarField,
inletOutletTotalTemperatureFvPatchScalarField
......
......@@ -146,7 +146,7 @@ void Foam::movingWallVelocityFvPatchVectorField::write(Ostream& os) const
namespace Foam
{
makePatchTypeField
makeNonTemplatedPatchTypeField
(
fvPatchVectorField,
movingWallVelocityFvPatchVectorField
......
......@@ -218,7 +218,7 @@ void Foam::pressureDirectedInletOutletVelocityFvPatchVectorField::operator=
namespace Foam
{
makePatchTypeField
makeNonTemplatedPatchTypeField
(
fvPatchVectorField,
pressureDirectedInletOutletVelocityFvPatchVectorField
......
......@@ -204,7 +204,7 @@ void Foam::pressureDirectedInletVelocityFvPatchVectorField::operator=
namespace Foam
{
makePatchTypeField
makeNonTemplatedPatchTypeField
(
fvPatchVectorField,
pressureDirectedInletVelocityFvPatchVectorField
......
......@@ -213,7 +213,7 @@ void Foam::pressureInletOutletVelocityFvPatchVectorField::operator=
namespace Foam
{
makePatchTypeField
makeNonTemplatedPatchTypeField
(
fvPatchVectorField,
pressureInletOutletVelocityFvPatchVectorField
......
......@@ -117,7 +117,7 @@ void Foam::pressureInletUniformVelocityFvPatchVectorField::operator=
namespace Foam
{
makePatchTypeField
makeNonTemplatedPatchTypeField
(
fvPatchVectorField,
pressureInletUniformVelocityFvPatchVectorField
......
......@@ -166,7 +166,7 @@ void Foam::pressureInletVelocityFvPatchVectorField::operator=
namespace Foam
{
makePatchTypeField
makeNonTemplatedPatchTypeField
(
fvPatchVectorField,
pressureInletVelocityFvPatchVectorField
......
......@@ -187,7 +187,7 @@ void Foam::pressureNormalInletOutletVelocityFvPatchVectorField::operator=
namespace Foam
{
makePatchTypeField
makeNonTemplatedPatchTypeField
(
fvPatchVectorField,
pressureNormalInletOutletVelocityFvPatchVectorField
......
......@@ -134,7 +134,7 @@ void Foam::rotatingPressureInletOutletVelocityFvPatchVectorField::write
namespace Foam
{
makePatchTypeField
makeNonTemplatedPatchTypeField
(
fvPatchVectorField,
rotatingPressureInletOutletVelocityFvPatchVectorField
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment