Back to index

salome-smesh  6.5.0
SMESH_Client.hxx
Go to the documentation of this file.
00001 // Copyright (C) 2007-2012  CEA/DEN, EDF R&D, OPEN CASCADE
00002 //
00003 // Copyright (C) 2003-2007  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
00004 // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
00005 //
00006 // This library is free software; you can redistribute it and/or
00007 // modify it under the terms of the GNU Lesser General Public
00008 // License as published by the Free Software Foundation; either
00009 // version 2.1 of the License.
00010 //
00011 // This library is distributed in the hope that it will be useful,
00012 // but WITHOUT ANY WARRANTY; without even the implied warranty of
00013 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00014 // Lesser General Public License for more details.
00015 //
00016 // You should have received a copy of the GNU Lesser General Public
00017 // License along with this library; if not, write to the Free Software
00018 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
00019 //
00020 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
00021 //
00022 
00023 //  SMESH SMESHClient : tool to update client mesh structure by mesh from server
00024 //  File   : SMESH_Client.hxx
00025 //  Author : Pavel TELKOV
00026 //  Module : SMESH
00027 //
00028 #ifndef _SMESH_Client_HeaderFile
00029 #define _SMESH_Client_HeaderFile
00030 
00031 #include <SALOMEconfig.h>
00032 #include CORBA_SERVER_HEADER(SMESH_Gen)
00033 #include CORBA_SERVER_HEADER(SMESH_Mesh)
00034 
00035 #ifdef WNT
00036 # if defined SMESHCLIENT_EXPORTS || defined SMESHClient_EXPORTS
00037 #  define SMESHCLIENT_EXPORT __declspec( dllexport )
00038 # else
00039 #  define SMESHCLIENT_EXPORT __declspec( dllimport )
00040 # endif
00041 #else
00042 # define SMESHCLIENT_EXPORT
00043 #endif
00044 
00045 class SMESHDS_Mesh;
00046 class SMDS_Mesh;
00047 
00048 
00049 //=====================================================================
00050 // SMESH_Client : class definition
00051 //=====================================================================
00052 class SMESHCLIENT_EXPORT SMESH_Client  
00053 {
00054 public:
00055   static 
00056   SMESH::SMESH_Gen_var
00057   GetSMESHGen(CORBA::ORB_ptr theORB,
00058               CORBA::Boolean& theIsEmbeddedMode);
00059 
00060   SMESH_Client(CORBA::ORB_ptr theORB,
00061                SMESH::SMESH_Mesh_ptr theMesh);
00062   ~SMESH_Client();
00063 
00064   bool 
00065   Update(bool theIsClear);
00066 
00067   SMDS_Mesh* 
00068   GetMesh() const;
00069 
00070   SMDS_Mesh*
00071   operator->() const;
00072 
00073   SMESH::SMESH_Mesh_ptr
00074   GetMeshServer();
00075 
00076 protected: 
00077   SMESH::SMESH_Mesh_var myMeshServer;
00078   SMESHDS_Mesh* mySMESHDSMesh;
00079   SMDS_Mesh* mySMDSMesh;
00080 };
00081 
00082 
00083 #endif