//=============================================================================
/*!
- *
+ * Return true if all sub-meshes have been meshed
*/
//=============================================================================
-bool SMESH_subMesh::subMeshesComputed()
+bool SMESH_subMesh::SubMeshesComputed() const
{
int myDim = SMESH_Gen::GetShapeDim( _subShape );
int dimToCheck = myDim - 1;
if (!algo->OnlyUnaryInput())
shape = getCollection( gen, algo, subComputed );
else
- subComputed = subMeshesComputed();
+ subComputed = SubMeshesComputed();
ret = ( algo->NeedDiscreteBoundary() ? subComputed :
algo->SupportSubmeshes() ? true :
( !subComputed || _father->IsNotConformAllowed() ));
SMESH_Algo* theAlgo,
bool & theSubComputed)
{
- theSubComputed = subMeshesComputed();
+ theSubComputed = SubMeshesComputed();
TopoDS_Shape mainShape = _father->GetMeshDS()->ShapeToMesh();
if (strcmp( anAlgo->GetName(), theAlgo->GetName()) == 0 && // same algo
anAlgo->GetUsedHypothesis( *_father, S, ignoreAuxiliaryHyps ) == aUsedHyp) // same hyps
aBuilder.Add( aCompound, S );
- if ( !subMesh->subMeshesComputed() )
+ if ( !subMesh->SubMeshesComputed() )
theSubComputed = false;
}
}
//================================================================================
SMESH_subMeshIteratorPtr SMESH_subMesh::getDependsOnIterator(const bool includeSelf,
- const bool reverse)
+ const bool reverse) const
{
+ SMESH_subMesh *me = (SMESH_subMesh*) this;
SMESH_subMesh *prepend=0, *append=0;
if ( includeSelf ) {
- if ( reverse ) prepend = this;
- else append = this;
+ if ( reverse ) prepend = me;
+ else append = me;
}
typedef map < int, SMESH_subMesh * > TMap;
if ( reverse )
{
return SMESH_subMeshIteratorPtr
- ( new _Iterator( new SMDS_mapReverseIterator<TMap>( DependsOn() ), prepend, append ));
+ ( new _Iterator( new SMDS_mapReverseIterator<TMap>( me->DependsOn() ), prepend, append ));
}
{
return SMESH_subMeshIteratorPtr
- ( new _Iterator( new SMDS_mapIterator<TMap>( DependsOn() ), prepend, append ));
+ ( new _Iterator( new SMDS_mapIterator<TMap>( me->DependsOn() ), prepend, append ));
}
}
* \brief Return iterator on the submeshes this one depends on
*/
SMESH_subMeshIteratorPtr getDependsOnIterator(const bool includeSelf,
- const bool complexShapeFirst);
+ const bool complexShapeFirst) const;
const TopoDS_Shape & GetSubShape() const;
void SetIsAlwaysComputed(bool isAlCo);
bool IsAlwaysComputed() { return _alwaysComputed; }
+ bool SubMeshesComputed() const;
+
/*!
* \brief Find common submeshes (based on shared subshapes with other
// ==================================================================
void insertDependence(const TopoDS_Shape aSubShape);
- bool subMeshesComputed();
- //bool SubMeshesReady();
-
void removeSubMeshElementsAndNodes();
void updateDependantsState(const compute_event theEvent);
void updateSubMeshState(const compute_state theState);