X-Git-Url: http://git.salome-platform.org/gitweb/?p=modules%2Fsmesh.git;a=blobdiff_plain;f=src%2FSMESH_I%2FSMESH_Gen_i.hxx;h=c78122345a1a3040e423c272cb2a78752622919f;hp=04edf2f1f42f33d42609cc380bbfe921873a4c19;hb=20c126bc220757c06b5576f71ed6f34ae85e3e40;hpb=d4a710ce52f6e76786a7b3845e2f7975dc9a00b1 diff --git a/src/SMESH_I/SMESH_Gen_i.hxx b/src/SMESH_I/SMESH_Gen_i.hxx index 04edf2f1f..c78122345 100644 --- a/src/SMESH_I/SMESH_Gen_i.hxx +++ b/src/SMESH_I/SMESH_Gen_i.hxx @@ -36,13 +36,15 @@ #include CORBA_CLIENT_HEADER(SALOMEDS) #include CORBA_CLIENT_HEADER(SALOMEDS_Attributes) +#include "SMESH_Gen.hxx" #include "SMESH_Mesh_i.hxx" #include "SMESH_Hypothesis_i.hxx" -#include "SALOME_Component_i.hxx" -#include "SALOME_NamingService.hxx" -#include "SMESH_Gen.hxx" -#include "GEOM_Client.hxx" +#include +#include +#include + +#include #include #include @@ -146,7 +148,7 @@ public: // Get SALOME_LifeCycleCORBA object static SALOME_LifeCycleCORBA* GetLCC(); // Retrieve and get GEOM engine reference - static GEOM::GEOM_Gen_ptr GetGeomEngine(); + static GEOM::GEOM_Gen_var GetGeomEngine(); // Get object of the CORBA reference static PortableServer::ServantBase_var GetServant( CORBA::Object_ptr theObject ); // Get CORBA object corresponding to the SALOMEDS::SObject @@ -238,7 +240,7 @@ public: SMESH::SMESH_Mesh_ptr CreateEmptyMesh() throw ( SALOME::SALOME_Exception ); - // Create mesh(es) and import data from UNV fileter + // Create a mesh and import data from an UNV file SMESH::SMESH_Mesh_ptr CreateMeshesFromUNV( const char* theFileName ) throw ( SALOME::SALOME_Exception ); @@ -252,7 +254,7 @@ public: SMESH::DriverMED_ReadStatus& theStatus ) throw ( SALOME::SALOME_Exception ); - // Create mesh(es) and import data from STL file + // Create a mesh and import data from a STL file SMESH::SMESH_Mesh_ptr CreateMeshesFromSTL( const char* theFileName ) throw ( SALOME::SALOME_Exception ); @@ -261,6 +263,12 @@ public: SMESH::DriverMED_ReadStatus& theStatus ) throw ( SALOME::SALOME_Exception ); + // Create a mesh and import data from a GMF file + SMESH::SMESH_Mesh_ptr CreateMeshesFromGMF( const char* theFileName, + CORBA::Boolean theMakeRequiredGroups, + SMESH::ComputeError_out theError) + throw ( SALOME::SALOME_Exception ); + // Copy a part of mesh SMESH::SMESH_Mesh_ptr CopyMesh(SMESH::SMESH_IDSource_ptr meshPart, const char* meshName, @@ -436,6 +444,12 @@ public: return aResultSO._retn(); } + // ============ + // Version information + // ============ + + virtual char* getVersion(); + // ============ // Dump python // ============ @@ -490,6 +504,7 @@ public: static long GetFaceGroupsTag(); static long GetVolumeGroupsTag(); static long Get0DElementsGroupsTag(); + static long GetBallElementsGroupsTag(); // publishing methods SALOMEDS::SComponent_ptr PublishComponent(SALOMEDS::Study_ptr theStudy); @@ -578,6 +593,9 @@ private: const char* theCommandNameForPython, const char* theFileNameForPython); + void setCurrentStudy( SALOMEDS::Study_ptr theStudy, + bool theStudyIsBeingClosed=false); + private: static GEOM::GEOM_Gen_var myGeomGen; static CORBA::ORB_var myOrb; // ORB reference @@ -614,6 +632,15 @@ namespace SMESH { return dynamic_cast(SMESH_Gen_i::GetServant(theArg).in()); } + + /*! + * \brief Function used in SMESH_CATCH to convert a caught exception to + * SALOME::SALOME_Exception + */ + inline void throwCorbaException(const char* excText) + { + THROW_SALOME_CORBA_EXCEPTION( excText, SALOME::INTERNAL_ERROR ); + } }