Commit 03338b9e authored by Mark Olesen's avatar Mark Olesen
Browse files

STYLE: partial revert for 5cfa9762

parent f7f6faa8
...@@ -27,8 +27,7 @@ License ...@@ -27,8 +27,7 @@ License
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
Foam::autoPtr<Foam::PDRDragModel> Foam::autoPtr<Foam::PDRDragModel> Foam::PDRDragModel::New
Foam::PDRDragModel::New
( (
const dictionary& PDRProperties, const dictionary& PDRProperties,
const compressible::RASModel& turbulence, const compressible::RASModel& turbulence,
...@@ -37,10 +36,7 @@ Foam::PDRDragModel::New ...@@ -37,10 +36,7 @@ Foam::PDRDragModel::New
const surfaceScalarField& phi const surfaceScalarField& phi
) )
{ {
const word modelType const word modelType(PDRProperties.lookup("PDRDragModel"));
(
PDRProperties.lookup("PDRDragModel")
);
Info<< "Selecting flame-wrinkling model " << modelType << endl; Info<< "Selecting flame-wrinkling model " << modelType << endl;
......
...@@ -27,19 +27,15 @@ License ...@@ -27,19 +27,15 @@ License
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
Foam::autoPtr<Foam::XiEqModel> Foam::autoPtr<Foam::XiEqModel> Foam::XiEqModel::New
Foam::XiEqModel::New
( (
const dictionary& XiEqProperties, const dictionary& propDict,
const hhuCombustionThermo& thermo, const hhuCombustionThermo& thermo,
const compressible::RASModel& turbulence, const compressible::RASModel& turbulence,
const volScalarField& Su const volScalarField& Su
) )
{ {
const word modelType const word modelType(propDict.lookup("XiEqModel"));
(
XiEqProperties.lookup("XiEqModel")
);
Info<< "Selecting flame-wrinkling model " << modelType << endl; Info<< "Selecting flame-wrinkling model " << modelType << endl;
...@@ -63,8 +59,7 @@ Foam::XiEqModel::New ...@@ -63,8 +59,7 @@ Foam::XiEqModel::New
<< exit(FatalError); << exit(FatalError);
} }
return autoPtr<XiEqModel> return autoPtr<XiEqModel>(cstrIter()(propDict, thermo, turbulence, Su));
(cstrIter()(XiEqProperties, thermo, turbulence, Su));
} }
......
...@@ -27,19 +27,15 @@ License ...@@ -27,19 +27,15 @@ License
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
Foam::autoPtr<Foam::XiGModel> Foam::autoPtr<Foam::XiGModel> Foam::XiGModel::New
Foam::XiGModel::New
( (
const dictionary& XiGProperties, const dictionary& propDict,
const hhuCombustionThermo& thermo, const hhuCombustionThermo& thermo,
const compressible::RASModel& turbulence, const compressible::RASModel& turbulence,
const volScalarField& Su const volScalarField& Su
) )
{ {
const word modelType const word modelType(propDict.lookup("XiGModel"));
(
XiGProperties.lookup("XiGModel")
);
Info<< "Selecting flame-wrinkling model " << modelType << endl; Info<< "Selecting flame-wrinkling model " << modelType << endl;
...@@ -63,8 +59,7 @@ Foam::XiGModel::New ...@@ -63,8 +59,7 @@ Foam::XiGModel::New
<< exit(FatalError); << exit(FatalError);
} }
return autoPtr<XiGModel> return autoPtr<XiGModel>(cstrIter()(propDict, thermo, turbulence, Su));
(cstrIter()(XiGProperties, thermo, turbulence, Su));
} }
......
...@@ -27,10 +27,9 @@ License ...@@ -27,10 +27,9 @@ License
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
Foam::autoPtr<Foam::XiModel> Foam::autoPtr<Foam::XiModel> Foam::XiModel::New
Foam::XiModel::New
( (
const dictionary& XiProperties, const dictionary& propDict,
const hhuCombustionThermo& thermo, const hhuCombustionThermo& thermo,
const compressible::RASModel& turbulence, const compressible::RASModel& turbulence,
const volScalarField& Su, const volScalarField& Su,
...@@ -39,10 +38,7 @@ Foam::XiModel::New ...@@ -39,10 +38,7 @@ Foam::XiModel::New
const surfaceScalarField& phi const surfaceScalarField& phi
) )
{ {
const word modelType const word modelType(propDict.lookup("XiModel"));
(
XiProperties.lookup("XiModel")
);
Info<< "Selecting flame-wrinkling model " << modelType << endl; Info<< "Selecting flame-wrinkling model " << modelType << endl;
...@@ -62,7 +58,7 @@ Foam::XiModel::New ...@@ -62,7 +58,7 @@ Foam::XiModel::New
} }
return autoPtr<XiModel> return autoPtr<XiModel>
(cstrIter()(XiProperties, thermo, turbulence, Su, rho, b, phi)); (cstrIter()(propDict, thermo, turbulence, Su, rho, b, phi));
} }
......
...@@ -27,23 +27,16 @@ License ...@@ -27,23 +27,16 @@ License
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
Foam::autoPtr<Foam::combustionModel> Foam::autoPtr<Foam::combustionModel> Foam::combustionModel::New
Foam::combustionModel::New
( (
const dictionary& combustionProperties, const dictionary& propDict,
const hsCombustionThermo& thermo, const hsCombustionThermo& thermo,
const compressible::turbulenceModel& turbulence, const compressible::turbulenceModel& turbulence,
const surfaceScalarField& phi, const surfaceScalarField& phi,
const volScalarField& rho const volScalarField& rho
) )
{ {
const word modelType const word modelType(propDict.lookup("combustionModel"));
(
combustionProperties.lookup
(
"combustionModel"
)
);
Info<< "Selecting combustion model " << modelType << endl; Info<< "Selecting combustion model " << modelType << endl;
...@@ -63,7 +56,7 @@ Foam::combustionModel::New ...@@ -63,7 +56,7 @@ Foam::combustionModel::New
} }
return autoPtr<combustionModel> return autoPtr<combustionModel>
(cstrIter()(combustionProperties, thermo, turbulence, phi, rho)); (cstrIter()(propDict, thermo, turbulence, phi, rho));
} }
......
...@@ -49,7 +49,7 @@ int main(int argc, char *argv[]) ...@@ -49,7 +49,7 @@ int main(int argc, char *argv[])
Info<< "\nStarting time loop\n" << endl; Info<< "\nStarting time loop\n" << endl;
autoPtr<Foam::motionSolver> motionPtr = motionSolver::New(mesh); autoPtr<motionSolver> motionPtr = motionSolver::New(mesh);
while (runTime.loop()) while (runTime.loop())
{ {
......
...@@ -37,7 +37,7 @@ Foam::phaseChangeTwoPhaseMixture::New ...@@ -37,7 +37,7 @@ Foam::phaseChangeTwoPhaseMixture::New
) )
{ {
// get model name, but do not register the dictionary // get model name, but do not register the dictionary
const word phaseChangeTwoPhaseMixtureTypeName const word mixtureType
( (
IOdictionary IOdictionary
( (
...@@ -53,12 +53,10 @@ Foam::phaseChangeTwoPhaseMixture::New ...@@ -53,12 +53,10 @@ Foam::phaseChangeTwoPhaseMixture::New
).lookup("phaseChangeTwoPhaseMixture") ).lookup("phaseChangeTwoPhaseMixture")
); );
Info<< "Selecting phaseChange model " Info<< "Selecting phaseChange model " << mixtureType << endl;
<< phaseChangeTwoPhaseMixtureTypeName << endl;
componentsConstructorTable::iterator cstrIter = componentsConstructorTable::iterator cstrIter =
componentsConstructorTablePtr_ componentsConstructorTablePtr_->find(mixtureType);
->find(phaseChangeTwoPhaseMixtureTypeName);
if (cstrIter == componentsConstructorTablePtr_->end()) if (cstrIter == componentsConstructorTablePtr_->end())
{ {
...@@ -66,7 +64,7 @@ Foam::phaseChangeTwoPhaseMixture::New ...@@ -66,7 +64,7 @@ Foam::phaseChangeTwoPhaseMixture::New
( (
"phaseChangeTwoPhaseMixture::New" "phaseChangeTwoPhaseMixture::New"
) << "Unknown phaseChangeTwoPhaseMixture type " ) << "Unknown phaseChangeTwoPhaseMixture type "
<< phaseChangeTwoPhaseMixtureTypeName << nl << nl << mixtureType << nl << nl
<< "Valid phaseChangeTwoPhaseMixture types are : " << endl << "Valid phaseChangeTwoPhaseMixture types are : " << endl
<< componentsConstructorTablePtr_->sortedToc() << componentsConstructorTablePtr_->sortedToc()
<< exit(FatalError); << exit(FatalError);
......
...@@ -27,8 +27,7 @@ License ...@@ -27,8 +27,7 @@ License
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
Foam::autoPtr<Foam::dragModel> Foam::autoPtr<Foam::dragModel> Foam::dragModel::New
Foam::dragModel::New
( (
const dictionary& interfaceDict, const dictionary& interfaceDict,
const volScalarField& alpha, const volScalarField& alpha,
...@@ -36,15 +35,10 @@ Foam::dragModel::New ...@@ -36,15 +35,10 @@ Foam::dragModel::New
const phaseModel& phaseb const phaseModel& phaseb
) )
{ {
const word modelType const word modelType(interfaceDict.lookup("dragModel" + phasea.name()));
(
interfaceDict.lookup("dragModel" + phasea.name())
);
Info<< "Selecting dragModel for phase " Info<< "Selecting dragModel for phase " << phasea.name()
<< phasea.name() << ": " << modelType << endl;
<< ": "
<< modelType << endl;
dictionaryConstructorTable::iterator cstrIter = dictionaryConstructorTable::iterator cstrIter =
dictionaryConstructorTablePtr_->find(modelType); dictionaryConstructorTablePtr_->find(modelType);
......
...@@ -27,16 +27,12 @@ License ...@@ -27,16 +27,12 @@ License
// * * * * * * * * * * * * * * * * Selectors * * * * * * * * * * * * * * * * // // * * * * * * * * * * * * * * * * Selectors * * * * * * * * * * * * * * * * //
Foam::autoPtr<Foam::conductivityModel> Foam::autoPtr<Foam::conductivityModel> Foam::conductivityModel::New
Foam::conductivityModel::New
( (
const dictionary& dict const dictionary& dict
) )
{ {
const word modelType const word modelType(dict.lookup("conductivityModel"));
(
dict.lookup("conductivityModel")
);
Info<< "Selecting conductivityModel " << modelType << endl; Info<< "Selecting conductivityModel " << modelType << endl;
......
...@@ -27,16 +27,12 @@ License ...@@ -27,16 +27,12 @@ License
// * * * * * * * * * * * * * * * * Selectors * * * * * * * * * * * * * * * * // // * * * * * * * * * * * * * * * * Selectors * * * * * * * * * * * * * * * * //
Foam::autoPtr<Foam::frictionalStressModel> Foam::autoPtr<Foam::frictionalStressModel> Foam::frictionalStressModel::New
Foam::frictionalStressModel::New
( (
const dictionary& dict const dictionary& dict
) )
{ {
const word modelType const word modelType(dict.lookup("frictionalStressModel"));
(
dict.lookup("frictionalStressModel")
);
Info<< "Selecting frictionalStressModel " << modelType << endl; Info<< "Selecting frictionalStressModel " << modelType << endl;
......
...@@ -27,16 +27,12 @@ License ...@@ -27,16 +27,12 @@ License
// * * * * * * * * * * * * * * * * Selectors * * * * * * * * * * * * * * * * // // * * * * * * * * * * * * * * * * Selectors * * * * * * * * * * * * * * * * //
Foam::autoPtr<Foam::granularPressureModel> Foam::autoPtr<Foam::granularPressureModel> Foam::granularPressureModel::New
Foam::granularPressureModel::New
( (
const dictionary& dict const dictionary& dict
) )
{ {
const word modelType const word modelType(dict.lookup("granularPressureModel"));
(
dict.lookup("granularPressureModel")
);
Info<< "Selecting granularPressureModel " << modelType << endl; Info<< "Selecting granularPressureModel " << modelType << endl;
......
...@@ -27,16 +27,12 @@ License ...@@ -27,16 +27,12 @@ License
// * * * * * * * * * * * * * * * * Selectors * * * * * * * * * * * * * * * * // // * * * * * * * * * * * * * * * * Selectors * * * * * * * * * * * * * * * * //
Foam::autoPtr<Foam::radialModel> Foam::autoPtr<Foam::radialModel> Foam::radialModel::New
Foam::radialModel::New
( (
const dictionary& dict const dictionary& dict
) )
{ {
const word modelType const word modelType(dict.lookup("radialModel"));
(
dict.lookup("radialModel")
);
Info<< "Selecting radialModel " << modelType << endl; Info<< "Selecting radialModel " << modelType << endl;
......
...@@ -33,10 +33,7 @@ Foam::kineticTheoryModels::viscosityModel::New ...@@ -33,10 +33,7 @@ Foam::kineticTheoryModels::viscosityModel::New
const dictionary& dict const dictionary& dict
) )
{ {
const word modelType const word modelType(dict.lookup("viscosityModel"));
(
dict.lookup("viscosityModel")
);
Info<< "Selecting viscosityModel " << modelType << endl; Info<< "Selecting viscosityModel " << modelType << endl;
......
...@@ -134,8 +134,7 @@ Foam::phaseModel::phaseModel ...@@ -134,8 +134,7 @@ Foam::phaseModel::phaseModel
} }
Foam::autoPtr<Foam::phaseModel> Foam::autoPtr<Foam::phaseModel> Foam::phaseModel::New
Foam::phaseModel::New
( (
const fvMesh& mesh, const fvMesh& mesh,
const dictionary& transportProperties, const dictionary& transportProperties,
......
...@@ -27,16 +27,12 @@ License ...@@ -27,16 +27,12 @@ License
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
Foam::autoPtr<Foam::extrudeModel> Foam::autoPtr<Foam::extrudeModel> Foam::extrudeModel::New
Foam::extrudeModel::New
( (
const dictionary& dict const dictionary& dict
) )
{ {
const word modelType const word modelType(dict.lookup("extrudeModel"));
(
dict.lookup("extrudeModel")
);
Info<< "Selecting extrudeModel " << modelType << endl; Info<< "Selecting extrudeModel " << modelType << endl;
......
...@@ -43,7 +43,7 @@ int main(int argc, char *argv[]) ...@@ -43,7 +43,7 @@ int main(int argc, char *argv[])
# include "createTime.H" # include "createTime.H"
# include "createMesh.H" # include "createMesh.H"
autoPtr<Foam::motionSolver> motionPtr = motionSolver::New(mesh); autoPtr<motionSolver> motionPtr = motionSolver::New(mesh);
while (runTime.loop()) while (runTime.loop())
{ {
......
...@@ -27,8 +27,7 @@ License ...@@ -27,8 +27,7 @@ License
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
Foam::autoPtr<Foam::ODESolver> Foam::autoPtr<Foam::ODESolver> Foam::ODESolver::New
Foam::ODESolver::New
( (
const Foam::word& ODESolverTypeName, const Foam::word& ODESolverTypeName,
const Foam::ODE& ode const Foam::ODE& ode
......
...@@ -52,8 +52,7 @@ Foam::token::compound::~compound() ...@@ -52,8 +52,7 @@ Foam::token::compound::~compound()
// * * * * * * * * * * * * * * * * Selectors * * * * * * * * * * * * * * * * // // * * * * * * * * * * * * * * * * Selectors * * * * * * * * * * * * * * * * //
Foam::autoPtr<Foam::token::compound> Foam::autoPtr<Foam::token::compound> Foam::token::compound::New
Foam::token::compound::New
( (
const word& compoundType, const word& compoundType,
Istream& is Istream& is
......
...@@ -118,8 +118,7 @@ Foam::dictionary::dictionary(Istream& is) ...@@ -118,8 +118,7 @@ Foam::dictionary::dictionary(Istream& is)
} }
Foam::autoPtr<Foam::dictionary> Foam::autoPtr<Foam::dictionary> Foam::dictionary::New(Istream& is)
Foam::dictionary::New(Istream& is)
{ {
return autoPtr<dictionary>(new dictionary(is)); return autoPtr<dictionary>(new dictionary(is));
} }
......
...@@ -191,8 +191,7 @@ bool Foam::entry::New(dictionary& parentDict, Istream& is) ...@@ -191,8 +191,7 @@ bool Foam::entry::New(dictionary& parentDict, Istream& is)
} }
Foam::autoPtr<Foam::entry> Foam::autoPtr<Foam::entry> Foam::entry::New(Istream& is)
Foam::entry::New(Istream& is)