static SMESH_HypoPredicate* HasDim(const int theDim);
static SMESH_HypoPredicate* HasType(const int theHypType);
+ bool IsEmpty() const { return myPredicates.empty(); }
+
/*!
* \brief check aHyp or/and aShape it is assigned to
*/
_libName = string(theLibName);
}
+//=======================================================================
+//function : GetMeshByPersistentID
+//purpose : Find a mesh with given persistent ID
+//=======================================================================
+
+SMESH_Mesh* SMESH_Hypothesis::GetMeshByPersistentID(int id)
+{
+ StudyContextStruct* myStudyContext = _gen->GetStudyContext(_studyId);
+ map<int, SMESH_Mesh*>::iterator itm = itm = myStudyContext->mapMesh.begin();
+ for ( ; itm != myStudyContext->mapMesh.end(); itm++)
+ {
+ SMESH_Mesh* mesh = (*itm).second;
+ if ( mesh->GetMeshDS()->GetPersistentId() == id )
+ return mesh;
+ }
+ return 0;
+}
+
//=============================================================================
/*!
*