mirror of
https://git.salome-platform.org/gitpub/modules/smesh.git
synced 2024-12-24 16:30:34 +05:00
20885 EDF 607 SMESH: Measure tools
interface SMESH_IDSource { + SMESH_Mesh GetMesh();
This commit is contained in:
parent
7fa71ad88e
commit
bc6dc0fb30
@ -248,6 +248,8 @@ module SMESH
|
||||
long_array elementConnectivities;
|
||||
types_array elementTypes; };
|
||||
|
||||
interface SMESH_Mesh;
|
||||
|
||||
interface SMESH_IDSource
|
||||
{
|
||||
/*!
|
||||
@ -265,6 +267,11 @@ module SMESH
|
||||
* Returns types of elements it contains
|
||||
*/
|
||||
array_of_ElementType GetTypes();
|
||||
|
||||
/*!
|
||||
* Returns the mesh
|
||||
*/
|
||||
SMESH_Mesh GetMesh();
|
||||
};
|
||||
|
||||
interface SMESH_Group;
|
||||
|
@ -367,8 +367,10 @@ struct _IDSource : public POA_SMESH::SMESH_IDSource
|
||||
{
|
||||
SMESH::long_array _ids;
|
||||
SMESH::ElementType _type;
|
||||
SMESH::SMESH_Mesh_ptr _mesh;
|
||||
SMESH::long_array* GetIDs() { return new SMESH::long_array( _ids ); }
|
||||
SMESH::long_array* GetMeshInfo() { return 0; }
|
||||
SMESH::SMESH_Mesh_ptr GetMesh() { return SMESH::SMESH_Mesh::_duplicate( _mesh ); }
|
||||
SMESH::array_of_ElementType* GetTypes()
|
||||
{
|
||||
SMESH::array_of_ElementType_var types = new SMESH::array_of_ElementType;
|
||||
@ -384,6 +386,7 @@ SMESH::SMESH_IDSource_ptr SMESH_MeshEditor_i::MakeIDSource(const SMESH::long_arr
|
||||
_IDSource* anIDSource = new _IDSource;
|
||||
anIDSource->_ids = ids;
|
||||
anIDSource->_type = type;
|
||||
anIDSource->_mesh = myMesh_i->_this();
|
||||
SMESH::SMESH_IDSource_var anIDSourceVar = anIDSource->_this();
|
||||
|
||||
return anIDSourceVar._retn();
|
||||
|
@ -3581,6 +3581,16 @@ SMESH::array_of_ElementType* SMESH_Mesh_i::GetTypes()
|
||||
return types._retn();
|
||||
}
|
||||
|
||||
//=======================================================================
|
||||
//function : GetMesh
|
||||
//purpose : Returns self
|
||||
//=======================================================================
|
||||
|
||||
SMESH::SMESH_Mesh_ptr SMESH_Mesh_i::GetMesh()
|
||||
{
|
||||
return SMESH::SMESH_Mesh::_duplicate( _this() );
|
||||
}
|
||||
|
||||
//=============================================================================
|
||||
/*!
|
||||
* \brief Returns statistic of mesh elements
|
||||
|
@ -521,18 +521,20 @@ public:
|
||||
// =========================
|
||||
|
||||
virtual SMESH::long_array* GetIDs();
|
||||
|
||||
/*!
|
||||
* Returns statistic of mesh elements
|
||||
* Result array of number enityties
|
||||
* Inherited from SMESH_IDSource
|
||||
*/
|
||||
virtual SMESH::long_array* GetMeshInfo();
|
||||
|
||||
/*!
|
||||
* Returns types of elements it contains
|
||||
*/
|
||||
virtual SMESH::array_of_ElementType* GetTypes();
|
||||
/*!
|
||||
* Returns self
|
||||
*/
|
||||
virtual SMESH::SMESH_Mesh_ptr GetMesh();
|
||||
|
||||
|
||||
std::map<int, SMESH_subMesh_i*> _mapSubMesh_i; //NRI
|
||||
|
@ -568,3 +568,13 @@ SMESH::array_of_ElementType* SMESH_subMesh_i::GetTypes()
|
||||
}
|
||||
return types._retn();
|
||||
}
|
||||
|
||||
//=======================================================================
|
||||
//function : GetMesh
|
||||
//purpose : interface SMESH_IDSource
|
||||
//=======================================================================
|
||||
|
||||
SMESH::SMESH_Mesh_ptr SMESH_subMesh_i::GetMesh()
|
||||
{
|
||||
return GetFather();
|
||||
}
|
||||
|
@ -85,19 +85,28 @@ public:
|
||||
SALOME_MED::FAMILY_ptr GetFamily()
|
||||
throw (SALOME::SALOME_Exception);
|
||||
|
||||
virtual SMESH::long_array* GetIDs();
|
||||
|
||||
// =========================
|
||||
// interface SMESH_IDSource
|
||||
// =========================
|
||||
/*!
|
||||
* Returns a sequence of all element IDs
|
||||
*/
|
||||
virtual SMESH::long_array* GetIDs();
|
||||
/*!
|
||||
* Returns statistic of mesh elements
|
||||
* Result array of number enityties
|
||||
* Inherited from SMESH_IDSource
|
||||
*/
|
||||
virtual SMESH::long_array* GetMeshInfo();
|
||||
|
||||
/*!
|
||||
* Returns types of elements it contains
|
||||
*/
|
||||
virtual SMESH::array_of_ElementType* GetTypes();
|
||||
/*!
|
||||
* Returns the mesh
|
||||
*/
|
||||
SMESH::SMESH_Mesh_ptr GetMesh();
|
||||
|
||||
|
||||
SMESH_Mesh_i* _mesh_i; //NRI
|
||||
|
Loading…
Reference in New Issue
Block a user