BUGFIX: new inletOutlet breaks with postfixedSubRegistry
This commit is contained in:
parent
e114bb940d
commit
a18d10c0aa
6 changed files with 24 additions and 2 deletions
|
@ -129,7 +129,9 @@ void inletOutletFvPatchField<Type>::updateCoeffs()
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!this->db().objectRegistry::found(phiName_))
|
// HR 2.1.19: Allow calls of virtual function in derived object registry
|
||||||
|
// eg. postFixedSubRegistry
|
||||||
|
if (!this->db().found(phiName_))
|
||||||
{
|
{
|
||||||
// Flux not available, do not update
|
// Flux not available, do not update
|
||||||
InfoIn
|
InfoIn
|
||||||
|
|
|
@ -70,7 +70,7 @@ void Foam::magLongDelta::makeMagLongDistance() const
|
||||||
<< abort(FatalError);
|
<< abort(FatalError);
|
||||||
}
|
}
|
||||||
|
|
||||||
// if (debug)
|
if (debug)
|
||||||
{
|
{
|
||||||
InfoIn("magLongDelta::makeMagLongDistance()")
|
InfoIn("magLongDelta::makeMagLongDistance()")
|
||||||
<< "Constructing magnitude of long cell distance"
|
<< "Constructing magnitude of long cell distance"
|
||||||
|
|
|
@ -212,6 +212,12 @@ const Foam::objectRegistry& Foam::objectRegistry::subRegistry
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
bool Foam::objectRegistry::found(const word& name) const
|
||||||
|
{
|
||||||
|
return HashTable<regIOobject*>::found(name);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
Foam::label Foam::objectRegistry::getEvent() const
|
Foam::label Foam::objectRegistry::getEvent() const
|
||||||
{
|
{
|
||||||
label curEvent = event_++;
|
label curEvent = event_++;
|
||||||
|
|
|
@ -187,6 +187,9 @@ public:
|
||||||
template<class Type>
|
template<class Type>
|
||||||
HashTable<Type*> lookupClass(const bool strict = false);
|
HashTable<Type*> lookupClass(const bool strict = false);
|
||||||
|
|
||||||
|
//- Is the object with name found?
|
||||||
|
virtual bool found(const word& name) const;
|
||||||
|
|
||||||
//- Is the named Type found?
|
//- Is the named Type found?
|
||||||
template<class Type>
|
template<class Type>
|
||||||
bool foundObject(const word& name) const;
|
bool foundObject(const word& name) const;
|
||||||
|
|
|
@ -140,4 +140,12 @@ bool Foam::postfixedSubRegistry::checkOut(regIOobject& io) const
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
bool Foam::postfixedSubRegistry::found(const word& objName) const
|
||||||
|
{
|
||||||
|
word demangledName = objName;
|
||||||
|
demangledName = demangledName(objName.size() - name().size());
|
||||||
|
return HashTable<regIOobject*>::found(demangledName);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
// ************************************************************************* //
|
// ************************************************************************* //
|
||||||
|
|
|
@ -88,6 +88,9 @@ public:
|
||||||
//- Return mangled fileName
|
//- Return mangled fileName
|
||||||
virtual fileName mangleFileName (const fileName&) const;
|
virtual fileName mangleFileName (const fileName&) const;
|
||||||
|
|
||||||
|
//- Is the object with name found?
|
||||||
|
virtual bool found(const word& name) const;
|
||||||
|
|
||||||
// Edit
|
// Edit
|
||||||
|
|
||||||
//- Add an regIOobject to registry
|
//- Add an regIOobject to registry
|
||||||
|
|
Reference in a new issue