// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
-// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
//
//
//
using namespace std;
#include "SMESH_Hypothesis.hxx"
#include "SMESH_Gen.hxx"
+#include "SMESH_subMesh.hxx"
#include "utilities.h"
//=============================================================================
StudyContextStruct* myStudyContext = _gen->GetStudyContext(_studyId);
myStudyContext->mapHypothesis[_hypId] = this;
_type = PARAM_ALGO;
-// _shapeType = -1; // to be set by algo with TopAbs_Enum
_shapeType = 0; // to be set by algo with TopAbs_Enum
+ _param_algo_dim = -1; // to be set by algo parameter
}
//=============================================================================
*/
//=============================================================================
-int SMESH_Hypothesis::GetDim()
+int SMESH_Hypothesis::GetDim() const
{
- int dim = -1;
+ int dim = 0;
switch (_type)
{
case ALGO_1D: dim = 1; break;
case ALGO_2D: dim = 2; break;
case ALGO_3D: dim = 3; break;
+ case PARAM_ALGO:
+ dim = ( _param_algo_dim < 0 ) ? -_param_algo_dim : _param_algo_dim; break;
}
return dim;
}
*/
//=============================================================================
-int SMESH_Hypothesis::GetShapeType()
+int SMESH_Hypothesis::GetShapeType() const
{
return _shapeType;
}
*/
//=============================================================================
-int SMESH_Hypothesis::GetStudyId()
+int SMESH_Hypothesis::GetStudyId() const
{
return _studyId;
}
itm++)
{
SMESH_Mesh* mesh = (*itm).second;
- const list<SMESH_subMesh*>& subMeshes =
- mesh->GetSubMeshUsingHypothesis(this);
+ mesh->NotifySubMeshesHypothesisModification( this );
+// const list<SMESH_subMesh*>& subMeshes =
+// mesh->GetSubMeshUsingHypothesis(this);
- //for all subMeshes using hypothesis
+// //for all subMeshes using hypothesis
- list<SMESH_subMesh*>::const_iterator its;
- for (its = subMeshes.begin(); its != subMeshes.end(); its++)
- (*its)->ComputeStateEngine(SMESH_subMesh::MODIF_HYP);
+// list<SMESH_subMesh*>::const_iterator its;
+// for (its = subMeshes.begin(); its != subMeshes.end(); its++)
+// (*its)->ComputeStateEngine(SMESH_subMesh::MODIF_HYP);
}
}
+//=============================================================================
+/*!
+ *
+ */
+//=============================================================================
+
+const char* SMESH_Hypothesis::GetLibName() const
+{
+// MESSAGE("SMESHDS_Hypothesis::GetLibName");
+// SCRUTE(_LibName);
+// SCRUTE(&_LibName);
+ return _libName.c_str();
+}
+
+//=============================================================================
+/*!
+ *
+ */
+//=============================================================================
+
+void SMESH_Hypothesis::SetLibName(const char* theLibName)
+{
+// MESSAGE("SMESHDS_Hypothesis::SetLibName");
+ _libName = string(theLibName);
+}