-// Copyright (C) 2007-2016 CEA/DEN, EDF R&D, OPEN CASCADE
+// Copyright (C) 2007-2021 CEA/DEN, EDF R&D, OPEN CASCADE
//
// Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
#include "Utils_SALOME_Exception.hxx"
#include <TopoDS_Shape.hxx>
+#include <TopTools_IndexedMapOfShape.hxx>
#include <list>
#include <map>
class SMESH_Mesh;
class SMESH_subMesh;
class SMESH_subMeshEventListener;
-class SMESH_subMeshEventListenerData;
+struct SMESH_subMeshEventListenerData;
typedef SMESH_subMeshEventListener EventListener;
typedef SMESH_subMeshEventListenerData EventListenerData;
// ==================================================================
/*!
- * \brief Sets an event listener and its data to a submesh
+ * \brief Set an event listener and its data to a submesh
* \param listener - the listener to store
* \param data - the listener data to store
* \param where - the submesh to store the listener and it's data
bool IsMeshComputed() const;
// check if _subMeshDS contains mesh elements unless _alwaysComputed==true
+ bool IsComputedPartially() const;
+ // check if any upper level sub-shape is not computed
+
+ /*!
+ * \brief Set sub-shapes that are allowed to compute at once by a multidimensional algo
+ */
+ void SetAllowedSubShapes( const TopTools_IndexedMapOfShape* subShapes )
+ { _allowedSubShapes = subShapes; }
+
/*!
* \brief Allow algo->Compute() if a subshape of lower dim is meshed but
* none mesh entity is bound to it
*/
void SetIsAlwaysComputed(bool isAlCo);
- bool IsAlwaysComputed() { return _alwaysComputed; }
+ bool IsAlwaysComputed() const { return _alwaysComputed; }
bool SubMeshesComputed(bool * isFailedToCompute=0) const;
std::vector< SMESH_subMesh * > _ancestors;
SMESH_Algo * _algo; // the algorithm found by last *StateEngine() call
+ TopoDS_Shape _algoShape; // shape the algorithm is assigned to
algo_state _algoState;
compute_state _computeState;
SMESH_ComputeErrorPtr _computeError;
// mesh several edges as a whole and leave some of them without mesh entities
bool _alwaysComputed;
+ const TopTools_IndexedMapOfShape* _allowedSubShapes; // allowed to be returned by getCollection()
+
};
#endif