Skip to content
Snippets Groups Projects
Commit cb36a393 authored by mattijs's avatar mattijs
Browse files

ENH: sets are now searched for.

Some tools now output sets at the pointsInstance (if relating to geometry),
some at the facesInstance (if relating to topology).
So when loading them we now search for them from current time down
to facesInstance. They cannot be beyond facesInstance.
Adapted Time::findInstance to take optional limiting instance. Adapted
topoSet to use this. Adapted all uses of IOobjectList on sets to do the
same.
parent 9962df5c
No related branches found
No related tags found
No related merge requests found
...@@ -400,25 +400,30 @@ void Foam::vtkPV3Foam::updateInfoSets ...@@ -400,25 +400,30 @@ void Foam::vtkPV3Foam::updateInfoSets
Info<< "<beg> Foam::vtkPV3Foam::updateInfoSets" << endl; Info<< "<beg> Foam::vtkPV3Foam::updateInfoSets" << endl;
} }
// Add names of sets // Add names of sets. Search for last time directory with a sets
IOobjectList objects // subdirectory. Take care not to search beyond the last mesh.
word facesInstance = dbPtr_().findInstance
( (
dbPtr_(), meshDir_,
dbPtr_().findInstance(meshDir_, "faces", IOobject::READ_IF_PRESENT), "faces",
meshDir_/"sets" IOobject::READ_IF_PRESENT
); );
word setsInstance = dbPtr_().findInstance
(
meshDir_/"sets",
word::null,
IOobject::READ_IF_PRESENT,
facesInstance
);
IOobjectList objects(dbPtr_(), setsInstance, meshDir_/"sets");
if (debug) if (debug)
{ {
Info<< " Foam::vtkPV3Foam::updateInfoSets read " Info<< " Foam::vtkPV3Foam::updateInfoSets read "
<< objects.names() << " from " << objects.names() << " from " << setsInstance << endl;
<< dbPtr_().findInstance
(
meshDir_,
"faces",
IOobject::READ_IF_PRESENT
)
<< endl;
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment