STYLE: more consistent New methods, use unregistered IOobject where appropriate

This commit is contained in:
Mark Olesen
2010-04-20 17:13:35 +02:00
parent 9707e5c100
commit 5cfa97624e
166 changed files with 1498 additions and 1540 deletions

View File

@ -27,25 +27,30 @@ License
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
Foam::autoPtr<Foam::extrudeModel> Foam::extrudeModel::New
Foam::autoPtr<Foam::extrudeModel>
Foam::extrudeModel::New
(
const dictionary& dict
)
{
word extrudeModelType(dict.lookup("extrudeModel"));
const word modelType
(
dict.lookup("extrudeModel")
);
Info<< "Selecting extrudeModel " << extrudeModelType << endl;
Info<< "Selecting extrudeModel " << modelType << endl;
dictionaryConstructorTable::iterator cstrIter =
dictionaryConstructorTablePtr_->find(extrudeModelType);
dictionaryConstructorTablePtr_->find(modelType);
if (cstrIter == dictionaryConstructorTablePtr_->end())
{
FatalErrorIn("extrudeModel::New(const dictionary&)")
<< "Unknown extrudeModelType type "
<< extrudeModelType
<< ", constructor not in hash table" << nl << nl
<< " Valid extrudeModel types are :" << nl
FatalErrorIn
(
"extrudeModel::New(const dictionary&)"
) << "Unknown extrudeModel type "
<< modelType << nl << nl
<< "Valid extrudeModel types are :" << nl
<< dictionaryConstructorTablePtr_->sortedToc() << nl
<< exit(FatalError);
}
@ -55,4 +60,3 @@ Foam::autoPtr<Foam::extrudeModel> Foam::extrudeModel::New
// ************************************************************************* //