#7727 Performance : Reduce amount of work

Use objectsWithReferringPtrFields to find tieIn wells
Avoid using descendantsOfType
This commit is contained in:
Magne Sjaastad
2021-05-27 11:44:26 +02:00
parent afb293db52
commit 33ac79d856
4 changed files with 50 additions and 47 deletions

View File

@@ -113,16 +113,18 @@ void RicWellPathExportCompletionDataFeature::prepareExportSettingsAndExportCompl
std::vector<RimWellPath*> allLaterals;
{
std::set<RimWellPath*> laterals;
std::set<RimWellPath*> lateralSet;
for ( auto t : topLevelWells )
{
auto laterals = t->wellPathLateralsRecursively();
auto laterals = t->allWellPathLaterals();
for ( auto l : laterals )
{
allLaterals.push_back( l );
lateralSet.insert( l );
}
}
allLaterals.assign( lateralSet.begin(), lateralSet.end() );
}
for ( auto w : allLaterals )