Commit bb67ccd3 authored by Andrew Heather's avatar Andrew Heather
Browse files

ENH: Cleaned up hash table item found checks

parent c1cbfe7a
......@@ -43,7 +43,7 @@ Foam::autoPtr<Foam::PDRDragModel> Foam::PDRDragModel::New
dictionaryConstructorTable::iterator cstrIter =
dictionaryConstructorTablePtr_->find(modelType);
if (cstrIter == dictionaryConstructorTablePtr_->end())
if (!cstrIter.found())
{
FatalErrorInFunction
<< "Unknown PDRDragModel type "
......
......@@ -42,7 +42,7 @@ Foam::autoPtr<Foam::XiEqModel> Foam::XiEqModel::New
dictionaryConstructorTable::iterator cstrIter =
dictionaryConstructorTablePtr_->find(modelType);
if (cstrIter == dictionaryConstructorTablePtr_->end())
if (!cstrIter.found())
{
FatalErrorInFunction
<< "Unknown XiEqModel type "
......
......@@ -42,7 +42,7 @@ Foam::autoPtr<Foam::XiGModel> Foam::XiGModel::New
dictionaryConstructorTable::iterator cstrIter =
dictionaryConstructorTablePtr_->find(modelType);
if (cstrIter == dictionaryConstructorTablePtr_->end())
if (!cstrIter.found())
{
FatalErrorInFunction
<< "Unknown XiGModel type "
......
......@@ -45,7 +45,7 @@ Foam::autoPtr<Foam::XiModel> Foam::XiModel::New
dictionaryConstructorTable::iterator cstrIter =
dictionaryConstructorTablePtr_->find(modelType);
if (cstrIter == dictionaryConstructorTablePtr_->end())
if (!cstrIter.found())
{
FatalErrorInFunction
<< "Unknown XiModel type "
......
......@@ -44,7 +44,7 @@ Foam::autoPtr<Foam::mixtureViscosityModel> Foam::mixtureViscosityModel::New
dictionaryConstructorTable::iterator cstrIter =
dictionaryConstructorTablePtr_->find(modelType);
if (cstrIter == dictionaryConstructorTablePtr_->end())
if (!cstrIter.found())
{
FatalErrorInFunction
<< "Unknown mixtureViscosityModel type "
......
......@@ -111,7 +111,7 @@ Foam::autoPtr<Foam::relativeVelocityModel> Foam::relativeVelocityModel::New
dictionaryConstructorTable::iterator cstrIter =
dictionaryConstructorTablePtr_->find(modelType);
if (cstrIter == dictionaryConstructorTablePtr_->end())
if (!cstrIter.found())
{
FatalErrorInFunction
<< "Unknown time scale model type " << modelType
......
......@@ -63,7 +63,7 @@ Foam::temperaturePhaseChangeTwoPhaseMixture::New
componentsConstructorTablePtr_
->find(temperaturePhaseChangeTwoPhaseMixtureTypeName);
if (cstrIter == componentsConstructorTablePtr_->end())
if (!cstrIter.found())
{
FatalErrorInFunction
<< "Unknown temperaturePhaseChangeTwoPhaseMixture type "
......
......@@ -60,7 +60,7 @@ Foam::phaseChangeTwoPhaseMixture::New
componentsConstructorTablePtr_
->find(phaseChangeTwoPhaseMixtureTypeName);
if (cstrIter == componentsConstructorTablePtr_->end())
if (!cstrIter.found())
{
FatalErrorInFunction
<< "Unknown phaseChangeTwoPhaseMixture type "
......
......@@ -44,7 +44,7 @@ Foam::autoPtr<Foam::dragModel> Foam::dragModel::New
dictionaryConstructorTable::iterator cstrIter =
dictionaryConstructorTablePtr_->find(dragModelType);
if (cstrIter == dictionaryConstructorTablePtr_->end())
if (!cstrIter.found())
{
FatalErrorInFunction
<< "Unknown dragModelType type "
......
......@@ -48,7 +48,7 @@ Foam::autoPtr<Foam::heatTransferModel> Foam::heatTransferModel::New
dictionaryConstructorTable::iterator cstrIter =
dictionaryConstructorTablePtr_->find(heatTransferModelType);
if (cstrIter == dictionaryConstructorTablePtr_->end())
if (!cstrIter.found())
{
FatalErrorInFunction
<< "Unknown heatTransferModelType type "
......
......@@ -46,7 +46,7 @@ Foam::autoPtr<Foam::diameterModel> Foam::diameterModel::New
dictionaryConstructorTable::iterator cstrIter =
dictionaryConstructorTablePtr_->find(diameterModelType);
if (cstrIter == dictionaryConstructorTablePtr_->end())
if (!cstrIter.found())
{
FatalErrorInFunction
<< "Unknown diameterModelType type "
......
......@@ -52,7 +52,7 @@ Foam::interfaceCompositionModel::New
dictionaryConstructorTable::iterator cstrIter =
dictionaryConstructorTablePtr_->find(interfaceCompositionModelType);
if (cstrIter == dictionaryConstructorTablePtr_->end())
if (!cstrIter.found())
{
FatalErrorInFunction
<< "Unknown interfaceCompositionModelType type "
......
......@@ -42,7 +42,7 @@ Foam::autoPtr<Foam::massTransferModel> Foam::massTransferModel::New
dictionaryConstructorTable::iterator cstrIter =
dictionaryConstructorTablePtr_->find(massTransferModelType);
if (cstrIter == dictionaryConstructorTablePtr_->end())
if (!cstrIter.found())
{
FatalErrorInFunction
<< "Unknown massTransferModelType type "
......
......@@ -40,7 +40,7 @@ Foam::autoPtr<Foam::saturationModel> Foam::saturationModel::New
dictionaryConstructorTable::iterator cstrIter =
dictionaryConstructorTablePtr_->find(saturationModelType);
if (cstrIter == dictionaryConstructorTablePtr_->end())
if (!cstrIter.found())
{
FatalErrorInFunction
<< "Unknown saturationModelType type "
......
......@@ -43,7 +43,7 @@ Foam::surfaceTensionModel::New
dictionaryConstructorTable::iterator cstrIter =
dictionaryConstructorTablePtr_->find(surfaceTensionModelType);
if (cstrIter == dictionaryConstructorTablePtr_->end())
if (!cstrIter.found())
{
FatalErrorInFunction
<< "Unknown surfaceTensionModelType type "
......
......@@ -43,7 +43,7 @@ Foam::aspectRatioModel::New
dictionaryConstructorTable::iterator cstrIter =
dictionaryConstructorTablePtr_->find(aspectRatioModelType);
if (cstrIter == dictionaryConstructorTablePtr_->end())
if (!cstrIter.found())
{
FatalErrorInFunction
<< "Unknown aspectRatioModelType type "
......
......@@ -42,7 +42,7 @@ Foam::autoPtr<Foam::dragModel> Foam::dragModel::New
dictionaryConstructorTable::iterator cstrIter =
dictionaryConstructorTablePtr_->find(dragModelType);
if (cstrIter == dictionaryConstructorTablePtr_->end())
if (!cstrIter.found())
{
FatalErrorInFunction
<< "Unknown dragModelType type "
......
......@@ -42,7 +42,7 @@ Foam::autoPtr<Foam::heatTransferModel> Foam::heatTransferModel::New
dictionaryConstructorTable::iterator cstrIter =
dictionaryConstructorTablePtr_->find(heatTransferModelType);
if (cstrIter == dictionaryConstructorTablePtr_->end())
if (!cstrIter.found())
{
FatalErrorInFunction
<< "Unknown heatTransferModelType type "
......
......@@ -42,7 +42,7 @@ Foam::autoPtr<Foam::liftModel> Foam::liftModel::New
dictionaryConstructorTable::iterator cstrIter =
dictionaryConstructorTablePtr_->find(liftModelType);
if (cstrIter == dictionaryConstructorTablePtr_->end())
if (!cstrIter.found())
{
FatalErrorInFunction
<< "Unknown liftModelType type "
......
......@@ -43,7 +43,7 @@ Foam::swarmCorrection::New
dictionaryConstructorTable::iterator cstrIter =
dictionaryConstructorTablePtr_->find(swarmCorrectionType);
if (cstrIter == dictionaryConstructorTablePtr_->end())
if (!cstrIter.found())
{
FatalErrorInFunction
<< "Unknown swarmCorrectionType type "
......
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