mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
ENH: revert to local interrogation of object registry contents
This commit is contained in:
@ -45,10 +45,19 @@ void MapDimensionedFields(const MeshMapper& mapper)
|
||||
typedef DimensionedField<Type, GeoMesh> FieldType;
|
||||
typedef HashTable<const FieldType*> TableType;
|
||||
|
||||
TableType fields
|
||||
(
|
||||
mapper.thisDb().objectRegistry::template lookupClass<FieldType>(true)
|
||||
);
|
||||
TableType fields(mapper.thisDb().size());
|
||||
|
||||
forAllConstIter(objectRegistry, mapper.thisDb(), iter)
|
||||
{
|
||||
if (isType<FieldType>(*iter()))
|
||||
{
|
||||
fields.insert
|
||||
(
|
||||
iter()->name(),
|
||||
dynamic_cast<const FieldType*>(iter())
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
forAllConstIter(typename TableType, fields, fieldIter)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user