Salome HOME
projects
/
modules
/
smesh.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge branch 'V9_9_BR'
[modules/smesh.git]
/
src
/
SMESHClient
/
SMESH_Client.cxx
diff --git
a/src/SMESHClient/SMESH_Client.cxx
b/src/SMESHClient/SMESH_Client.cxx
index a2a29c7bc38a02fa74f79506667f1ac770bf9966..1cb0456812bc63b7d1678b21ab6fd2d1713556e9 100644
(file)
--- a/
src/SMESHClient/SMESH_Client.cxx
+++ b/
src/SMESHClient/SMESH_Client.cxx
@@
-1,4
+1,4
@@
-// Copyright (C) 2007-20
16
CEA/DEN, EDF R&D, OPEN CASCADE
+// Copyright (C) 2007-20
22
CEA/DEN, EDF R&D, OPEN CASCADE
//
// Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
//
// Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
@@
-24,17
+24,22
@@
// Module : SMESH
#include "SMESH_Client.hxx"
// Module : SMESH
#include "SMESH_Client.hxx"
-#include "SMESH_Mesh.hxx"
+
+#include "SMESHDS_Mesh.hxx"
#include "SMESHDS_Script.hxx"
#include "SMESHDS_Script.hxx"
+#include "SMESH_Mesh.hxx"
#include "SALOME_NamingService.hxx"
#include "SALOME_NamingService.hxx"
+#include "SALOME_Fake_NamingService.hxx"
#include "SALOME_LifeCycleCORBA.hxx"
#include <SALOMEconfig.h>
#include "SALOME_LifeCycleCORBA.hxx"
#include <SALOMEconfig.h>
+#include <smIdType.hxx>
#include CORBA_SERVER_HEADER(SALOME_Component)
#include CORBA_SERVER_HEADER(SALOME_Exception)
#include "Basics_Utils.hxx"
#include CORBA_SERVER_HEADER(SALOME_Component)
#include CORBA_SERVER_HEADER(SALOME_Exception)
#include "Basics_Utils.hxx"
+#include "KernelBasis.hxx"
#include "utilities.h"
#ifdef WIN32
#include "utilities.h"
#ifdef WIN32
@@
-44,6
+49,7
@@
#endif
#include <stdexcept>
#endif
#include <stdexcept>
+#include <memory>
#ifndef EXCEPTION
#define EXCEPTION(TYPE, MSG) {\
#ifndef EXCEPTION
#define EXCEPTION(TYPE, MSG) {\
@@
-54,7
+60,7
@@
#endif
#ifdef _DEBUG_
#endif
#ifdef _DEBUG_
-static int MYDEBUG =
1
;
+static int MYDEBUG =
0
;
#else
static int MYDEBUG = 0;
#endif
#else
static int MYDEBUG = 0;
#endif
@@
-86,14
+92,14
@@
namespace
//=======================================================================
inline void AddNodesWithID(SMDS_Mesh* theMesh,
SMESH::log_array_var& theSeq,
//=======================================================================
inline void AddNodesWithID(SMDS_Mesh* theMesh,
SMESH::log_array_var& theSeq,
-
CORBA::Long
theId)
+
SMESH::smIdType
theId)
{
const SMESH::double_array& aCoords = theSeq[theId].coords;
const SMESH::long_array& anIndexes = theSeq[theId].indexes;
{
const SMESH::double_array& aCoords = theSeq[theId].coords;
const SMESH::long_array& anIndexes = theSeq[theId].indexes;
-
CORBA::Long
anElemId = 0, aNbElems = theSeq[theId].number;
- if(3*aNbElems != (
CORBA::Long
) aCoords.length())
+
SMESH::smIdType
anElemId = 0, aNbElems = theSeq[theId].number;
+ if(3*aNbElems != (
SMESH::smIdType
) aCoords.length())
EXCEPTION(runtime_error,"AddNodesWithID - 3*aNbElems != aCoords.length()");
EXCEPTION(runtime_error,"AddNodesWithID - 3*aNbElems != aCoords.length()");
- for(
CORBA::Long
aCoordId = 0; anElemId < aNbElems; anElemId++, aCoordId+=3){
+ for(
SMESH::smIdType
aCoordId = 0; anElemId < aNbElems; anElemId++, aCoordId+=3){
SMDS_MeshElement* anElem = theMesh->AddNodeWithID(aCoords[aCoordId],
aCoords[aCoordId+1],
aCoords[aCoordId+2],
SMDS_MeshElement* anElem = theMesh->AddNodeWithID(aCoords[aCoordId],
aCoords[aCoordId+1],
aCoords[aCoordId+2],
@@
-109,13
+115,13
@@
namespace
//=======================================================================
inline void Add0DElementsWithID(SMDS_Mesh* theMesh,
SMESH::log_array_var& theSeq,
//=======================================================================
inline void Add0DElementsWithID(SMDS_Mesh* theMesh,
SMESH::log_array_var& theSeq,
-
CORBA::Long
theId)
+
SMESH::smIdType
theId)
{
const SMESH::long_array& anIndexes = theSeq[theId].indexes;
{
const SMESH::long_array& anIndexes = theSeq[theId].indexes;
-
CORBA::Long
anElemId = 0, aNbElems = theSeq[theId].number;
- if (2*aNbElems != (
CORBA::Long
) anIndexes.length())
+
SMESH::smIdType
anElemId = 0, aNbElems = theSeq[theId].number;
+ if (2*aNbElems != (
SMESH::smIdType
) anIndexes.length())
EXCEPTION(runtime_error,"AddEdgeWithID - 2*aNbElems != aCoords.length()");
EXCEPTION(runtime_error,"AddEdgeWithID - 2*aNbElems != aCoords.length()");
-
CORBA::Long
anIndexId = 0;
+
SMESH::smIdType
anIndexId = 0;
for (; anElemId < aNbElems; anElemId++, anIndexId+=2)
{
SMDS_MeshElement* anElem = theMesh->Add0DElementWithID(anIndexes[anIndexId+1],
for (; anElemId < aNbElems; anElemId++, anIndexId+=2)
{
SMDS_MeshElement* anElem = theMesh->Add0DElementWithID(anIndexes[anIndexId+1],
@@
-131,16
+137,16
@@
namespace
//=======================================================================
inline void AddBallsWithID(SMDS_Mesh* theMesh,
SMESH::log_array_var& theSeq,
//=======================================================================
inline void AddBallsWithID(SMDS_Mesh* theMesh,
SMESH::log_array_var& theSeq,
-
CORBA::Long
theId)
+
SMESH::smIdType
theId)
{
const SMESH::double_array& aDiameter = theSeq[theId].coords;
const SMESH::long_array& anIndexes = theSeq[theId].indexes;
{
const SMESH::double_array& aDiameter = theSeq[theId].coords;
const SMESH::long_array& anIndexes = theSeq[theId].indexes;
-
CORBA::Long
anElemId = 0, aNbElems = theSeq[theId].number;
- if (2*aNbElems != (
CORBA::Long
) anIndexes.length() )
+
SMESH::smIdType
anElemId = 0, aNbElems = theSeq[theId].number;
+ if (2*aNbElems != (
SMESH::smIdType
) anIndexes.length() )
EXCEPTION(runtime_error,"AddEdgeWithID - 2*aNbElems != anIndexes.length()");
EXCEPTION(runtime_error,"AddEdgeWithID - 2*aNbElems != anIndexes.length()");
- if (aNbElems != (
CORBA::Long
) aDiameter.length())
+ if (aNbElems != (
SMESH::smIdType
) aDiameter.length())
EXCEPTION(runtime_error,"AddEdgeWithID - aNbElems != aDiameter.length()");
EXCEPTION(runtime_error,"AddEdgeWithID - aNbElems != aDiameter.length()");
-
CORBA::Long
anIndexId = 0;
+
SMESH::smIdType
anIndexId = 0;
for (; anElemId < aNbElems; anElemId++, anIndexId+=2)
{
SMDS_MeshElement* anElem = theMesh->AddBallWithID(anIndexes[anIndexId+1],
for (; anElemId < aNbElems; anElemId++, anIndexId+=2)
{
SMDS_MeshElement* anElem = theMesh->AddBallWithID(anIndexes[anIndexId+1],
@@
-157,13
+163,13
@@
namespace
//=======================================================================
inline void AddEdgesWithID(SMDS_Mesh* theMesh,
SMESH::log_array_var& theSeq,
//=======================================================================
inline void AddEdgesWithID(SMDS_Mesh* theMesh,
SMESH::log_array_var& theSeq,
-
CORBA::Long
theId)
+
SMESH::smIdType
theId)
{
const SMESH::long_array& anIndexes = theSeq[theId].indexes;
{
const SMESH::long_array& anIndexes = theSeq[theId].indexes;
-
CORBA::Long
anElemId = 0, aNbElems = theSeq[theId].number;
- if(3*aNbElems != (
CORBA::Long
) anIndexes.length())
+
SMESH::smIdType
anElemId = 0, aNbElems = theSeq[theId].number;
+ if(3*aNbElems != (
SMESH::smIdType
) anIndexes.length())
EXCEPTION(runtime_error,"AddEdgeWithID - 3*aNbElems != aCoords.length()");
EXCEPTION(runtime_error,"AddEdgeWithID - 3*aNbElems != aCoords.length()");
- for(
CORBA::Long
anIndexId = 0; anElemId < aNbElems; anElemId++, anIndexId+=3){
+ for(
SMESH::smIdType
anIndexId = 0; anElemId < aNbElems; anElemId++, anIndexId+=3){
SMDS_MeshElement* anElem = theMesh->AddEdgeWithID(anIndexes[anIndexId+1],
anIndexes[anIndexId+2],
anIndexes[anIndexId]);
SMDS_MeshElement* anElem = theMesh->AddEdgeWithID(anIndexes[anIndexId+1],
anIndexes[anIndexId+2],
anIndexes[anIndexId]);
@@
-178,13
+184,13
@@
namespace
//=======================================================================
inline void AddTriasWithID(SMDS_Mesh* theMesh,
SMESH::log_array_var& theSeq,
//=======================================================================
inline void AddTriasWithID(SMDS_Mesh* theMesh,
SMESH::log_array_var& theSeq,
-
CORBA::Long
theId)
+
SMESH::smIdType
theId)
{
const SMESH::long_array& anIndexes = theSeq[theId].indexes;
{
const SMESH::long_array& anIndexes = theSeq[theId].indexes;
-
CORBA::Long
anElemId = 0, aNbElems = theSeq[theId].number;
- if(4*aNbElems != (
CORBA::Long
) anIndexes.length())
+
SMESH::smIdType
anElemId = 0, aNbElems = theSeq[theId].number;
+ if(4*aNbElems != (
SMESH::smIdType
) anIndexes.length())
EXCEPTION(runtime_error,"AddTriasWithID - 4*aNbElems != anIndexes.length()");
EXCEPTION(runtime_error,"AddTriasWithID - 4*aNbElems != anIndexes.length()");
- for(
CORBA::Long
anIndexId = 0; anElemId < aNbElems; anElemId++, anIndexId+=4){
+ for(
SMESH::smIdType
anIndexId = 0; anElemId < aNbElems; anElemId++, anIndexId+=4){
SMDS_MeshElement* anElem = theMesh->AddFaceWithID(anIndexes[anIndexId+1],
anIndexes[anIndexId+2],
anIndexes[anIndexId+3],
SMDS_MeshElement* anElem = theMesh->AddFaceWithID(anIndexes[anIndexId+1],
anIndexes[anIndexId+2],
anIndexes[anIndexId+3],
@@
-200,13
+206,13
@@
namespace
//=======================================================================
inline void AddQuadsWithID(SMDS_Mesh* theMesh,
SMESH::log_array_var theSeq,
//=======================================================================
inline void AddQuadsWithID(SMDS_Mesh* theMesh,
SMESH::log_array_var theSeq,
-
CORBA::Long
theId)
+
SMESH::smIdType
theId)
{
const SMESH::long_array& anIndexes = theSeq[theId].indexes;
{
const SMESH::long_array& anIndexes = theSeq[theId].indexes;
-
CORBA::Long
anElemId = 0, aNbElems = theSeq[theId].number;
- if(5*aNbElems != (
CORBA::Long
) anIndexes.length())
+
SMESH::smIdType
anElemId = 0, aNbElems = theSeq[theId].number;
+ if(5*aNbElems != (
SMESH::smIdType
) anIndexes.length())
EXCEPTION(runtime_error,"AddQuadsWithID - 4*aNbElems != anIndexes.length()");
EXCEPTION(runtime_error,"AddQuadsWithID - 4*aNbElems != anIndexes.length()");
- for(
CORBA::Long
anIndexId = 0; anElemId < aNbElems; anElemId++, anIndexId+=5){
+ for(
SMESH::smIdType
anIndexId = 0; anElemId < aNbElems; anElemId++, anIndexId+=5){
SMDS_MeshElement* anElem = theMesh->AddFaceWithID(anIndexes[anIndexId+1],
anIndexes[anIndexId+2],
anIndexes[anIndexId+3],
SMDS_MeshElement* anElem = theMesh->AddFaceWithID(anIndexes[anIndexId+1],
anIndexes[anIndexId+2],
anIndexes[anIndexId+3],
@@
-223,16
+229,16
@@
namespace
//=======================================================================
inline void AddPolygonsWithID(SMDS_Mesh* theMesh,
SMESH::log_array_var& theSeq,
//=======================================================================
inline void AddPolygonsWithID(SMDS_Mesh* theMesh,
SMESH::log_array_var& theSeq,
-
CORBA::Long
theId)
+
SMESH::smIdType
theId)
{
const SMESH::long_array& anIndexes = theSeq[theId].indexes;
{
const SMESH::long_array& anIndexes = theSeq[theId].indexes;
-
CORBA::Long
anIndexId = 0, aNbElems = theSeq[theId].number;
+
SMESH::smIdType
anIndexId = 0, aNbElems = theSeq[theId].number;
- for (
CORBA::Long
anElemId = 0; anElemId < aNbElems; anElemId++) {
-
int
aFaceId = anIndexes[anIndexId++];
+ for (
SMESH::smIdType
anElemId = 0; anElemId < aNbElems; anElemId++) {
+
smIdType
aFaceId = anIndexes[anIndexId++];
int aNbNodes = anIndexes[anIndexId++];
int aNbNodes = anIndexes[anIndexId++];
- std::vector<
int
> nodes_ids (aNbNodes);
+ std::vector<
smIdType
> nodes_ids (aNbNodes);
for (int i = 0; i < aNbNodes; i++) {
nodes_ids[i] = anIndexes[anIndexId++];
}
for (int i = 0; i < aNbNodes; i++) {
nodes_ids[i] = anIndexes[anIndexId++];
}
@@
-250,16
+256,16
@@
namespace
//=======================================================================
inline void AddQuadPolygonsWithID(SMDS_Mesh* theMesh,
SMESH::log_array_var& theSeq,
//=======================================================================
inline void AddQuadPolygonsWithID(SMDS_Mesh* theMesh,
SMESH::log_array_var& theSeq,
-
CORBA::Long
theId)
+
SMESH::smIdType
theId)
{
const SMESH::long_array& anIndexes = theSeq[theId].indexes;
{
const SMESH::long_array& anIndexes = theSeq[theId].indexes;
-
CORBA::Long
anIndexId = 0, aNbElems = theSeq[theId].number;
+
SMESH::smIdType
anIndexId = 0, aNbElems = theSeq[theId].number;
- for (
CORBA::Long
anElemId = 0; anElemId < aNbElems; anElemId++) {
-
int
aFaceId = anIndexes[anIndexId++];
+ for (
SMESH::smIdType
anElemId = 0; anElemId < aNbElems; anElemId++) {
+
smIdType
aFaceId = anIndexes[anIndexId++];
int aNbNodes = anIndexes[anIndexId++];
int aNbNodes = anIndexes[anIndexId++];
- std::vector<
int
> nodes_ids (aNbNodes);
+ std::vector<
smIdType
> nodes_ids (aNbNodes);
for (int i = 0; i < aNbNodes; i++) {
nodes_ids[i] = anIndexes[anIndexId++];
}
for (int i = 0; i < aNbNodes; i++) {
nodes_ids[i] = anIndexes[anIndexId++];
}
@@
-277,13
+283,13
@@
namespace
//=======================================================================
inline void AddTetrasWithID(SMDS_Mesh* theMesh,
SMESH::log_array_var& theSeq,
//=======================================================================
inline void AddTetrasWithID(SMDS_Mesh* theMesh,
SMESH::log_array_var& theSeq,
-
CORBA::Long
theId)
+
SMESH::smIdType
theId)
{
const SMESH::long_array& anIndexes = theSeq[theId].indexes;
{
const SMESH::long_array& anIndexes = theSeq[theId].indexes;
-
CORBA::Long
anElemId = 0, aNbElems = theSeq[theId].number;
- if(5*aNbElems != (
CORBA::Long
) anIndexes.length())
+
SMESH::smIdType
anElemId = 0, aNbElems = theSeq[theId].number;
+ if(5*aNbElems != (
SMESH::smIdType
) anIndexes.length())
EXCEPTION(runtime_error,"AddTetrasWithID - 5*aNbElems != anIndexes.length()");
EXCEPTION(runtime_error,"AddTetrasWithID - 5*aNbElems != anIndexes.length()");
- for(
CORBA::Long
anIndexId = 0; anElemId < aNbElems; anElemId++, anIndexId+=5){
+ for(
SMESH::smIdType
anIndexId = 0; anElemId < aNbElems; anElemId++, anIndexId+=5){
SMDS_MeshElement* anElem = theMesh->AddVolumeWithID(anIndexes[anIndexId+1],
anIndexes[anIndexId+2],
anIndexes[anIndexId+3],
SMDS_MeshElement* anElem = theMesh->AddVolumeWithID(anIndexes[anIndexId+1],
anIndexes[anIndexId+2],
anIndexes[anIndexId+3],
@@
-300,13
+306,13
@@
namespace
//=======================================================================
inline void AddPiramidsWithID(SMDS_Mesh* theMesh,
SMESH::log_array_var& theSeq,
//=======================================================================
inline void AddPiramidsWithID(SMDS_Mesh* theMesh,
SMESH::log_array_var& theSeq,
-
CORBA::Long
theId)
+
SMESH::smIdType
theId)
{
const SMESH::long_array& anIndexes = theSeq[theId].indexes;
{
const SMESH::long_array& anIndexes = theSeq[theId].indexes;
-
CORBA::Long
anElemId = 0, aNbElems = theSeq[theId].number;
- if(6*aNbElems != (
CORBA::Long
) anIndexes.length())
+
SMESH::smIdType
anElemId = 0, aNbElems = theSeq[theId].number;
+ if(6*aNbElems != (
SMESH::smIdType
) anIndexes.length())
EXCEPTION(runtime_error,"AddPiramidsWithID - 6*aNbElems != anIndexes.length()");
EXCEPTION(runtime_error,"AddPiramidsWithID - 6*aNbElems != anIndexes.length()");
- for(
CORBA::Long
anIndexId = 0; anElemId < aNbElems; anElemId++, anIndexId+=6){
+ for(
SMESH::smIdType
anIndexId = 0; anElemId < aNbElems; anElemId++, anIndexId+=6){
SMDS_MeshElement* anElem = theMesh->AddVolumeWithID(anIndexes[anIndexId+1],
anIndexes[anIndexId+2],
anIndexes[anIndexId+3],
SMDS_MeshElement* anElem = theMesh->AddVolumeWithID(anIndexes[anIndexId+1],
anIndexes[anIndexId+2],
anIndexes[anIndexId+3],
@@
-324,7
+330,7
@@
namespace
//=======================================================================
inline void AddPrismsWithID(SMDS_Mesh* theMesh,
SMESH::log_array_var& theSeq,
//=======================================================================
inline void AddPrismsWithID(SMDS_Mesh* theMesh,
SMESH::log_array_var& theSeq,
-
CORBA::Long
theId)
+
SMESH::smIdType
theId)
{
const SMESH::long_array& anIndexes = theSeq[theId].indexes;
CORBA::Long anElemId = 0, aNbElems = theSeq[theId].number;
{
const SMESH::long_array& anIndexes = theSeq[theId].indexes;
CORBA::Long anElemId = 0, aNbElems = theSeq[theId].number;
@@
-412,10
+418,10
@@
namespace
CORBA::Long anIndexId = 0, aNbElems = theSeq[theId].number;
for (CORBA::Long anElemId = 0; anElemId < aNbElems; anElemId++) {
CORBA::Long anIndexId = 0, aNbElems = theSeq[theId].number;
for (CORBA::Long anElemId = 0; anElemId < aNbElems; anElemId++) {
-
int
aFaceId = anIndexes[anIndexId++];
+
smIdType
aFaceId = anIndexes[anIndexId++];
int aNbNodes = anIndexes[anIndexId++];
int aNbNodes = anIndexes[anIndexId++];
- std::vector<
int
> nodes_ids (aNbNodes);
+ std::vector<
smIdType
> nodes_ids (aNbNodes);
for (int i = 0; i < aNbNodes; i++) {
nodes_ids[i] = anIndexes[anIndexId++];
}
for (int i = 0; i < aNbNodes; i++) {
nodes_ids[i] = anIndexes[anIndexId++];
}
@@
-743,9
+749,9
@@
namespace
//=======================================================================
//function : ChangePolyhedronNodes
//=======================================================================
//=======================================================================
//function : ChangePolyhedronNodes
//=======================================================================
- inline void ChangePolyhedronNodes (SMDS_Mesh* theMesh,
+ inline void ChangePolyhedronNodes (SMDS_Mesh*
theMesh,
SMESH::log_array_var& theSeq,
SMESH::log_array_var& theSeq,
- CORBA::Long theId)
+ CORBA::Long
theId)
{
const SMESH::long_array& anIndexes = theSeq[theId].indexes;
CORBA::Long iind = 0, aNbElems = theSeq[theId].number;
{
const SMESH::long_array& anIndexes = theSeq[theId].indexes;
CORBA::Long iind = 0, aNbElems = theSeq[theId].number;
@@
-781,15
+787,24
@@
SMESH_Client::GetSMESHGen(CORBA::ORB_ptr theORB,
{
static SMESH::SMESH_Gen_var aMeshGen;
{
static SMESH::SMESH_Gen_var aMeshGen;
- if(CORBA::is_nil(aMeshGen.in())){
+ if(CORBA::is_nil(aMeshGen.in()))
+ {
#ifdef WIN32
long aClientPID = (long)_getpid();
#else
long aClientPID = (long)getpid();
#endif
#ifdef WIN32
long aClientPID = (long)_getpid();
#else
long aClientPID = (long)getpid();
#endif
- SALOME_NamingService aNamingService(theORB);
- SALOME_LifeCycleCORBA aLifeCycleCORBA(&aNamingService);
+ std::unique_ptr<SALOME_NamingService_Abstract> aNamingService;
+ if(getSSLMode())
+ {
+ aNamingService.reset(new SALOME_Fake_NamingService);
+ }
+ else
+ {
+ aNamingService.reset(new SALOME_NamingService(theORB));
+ }
+ SALOME_LifeCycleCORBA aLifeCycleCORBA(aNamingService.get());
Engines::EngineComponent_var aComponent = aLifeCycleCORBA.FindOrLoad_Component("FactoryServer","SMESH");
aMeshGen = SMESH::SMESH_Gen::_narrow(aComponent);
Engines::EngineComponent_var aComponent = aLifeCycleCORBA.FindOrLoad_Component("FactoryServer","SMESH");
aMeshGen = SMESH::SMESH_Gen::_narrow(aComponent);
@@
-800,7
+815,6
@@
SMESH_Client::GetSMESHGen(CORBA::ORB_ptr theORB,
aMeshGen->SetEmbeddedMode((aClientPID == aServerPID) && (aClientHostName == aServerHostName.in()));
}
theIsEmbeddedMode = aMeshGen->IsEmbeddedMode();
aMeshGen->SetEmbeddedMode((aClientPID == aServerPID) && (aClientHostName == aServerHostName.in()));
}
theIsEmbeddedMode = aMeshGen->IsEmbeddedMode();
-
return aMeshGen;
}
return aMeshGen;
}
@@
-815,22
+829,19
@@
SMESH_Client::SMESH_Client(CORBA::ORB_ptr theORB,
mySMESHDSMesh(NULL),
mySMDSMesh(NULL)
{
mySMESHDSMesh(NULL),
mySMDSMesh(NULL)
{
- MESSAGE("SMESH_Client::SMESH_Client");
+
if ( MYDEBUG )
MESSAGE("SMESH_Client::SMESH_Client");
myMeshServer->Register();
CORBA::Boolean anIsEmbeddedMode;
GetSMESHGen(theORB,anIsEmbeddedMode);
if(anIsEmbeddedMode){
myMeshServer->Register();
CORBA::Boolean anIsEmbeddedMode;
GetSMESHGen(theORB,anIsEmbeddedMode);
if(anIsEmbeddedMode){
- if ( MYDEBUG )
- MESSAGE("Info: The same process, update mesh by pointer ");
+ if ( MYDEBUG ) MESSAGE("Info: The same process, update mesh by pointer ");
// just set client mesh pointer to server mesh pointer
//SMESH_Mesh* aMesh = reinterpret_cast<SMESH_Mesh*>(theMesh->GetMeshPtr());
CORBA::LongLong pointeur = theMesh->GetMeshPtr();
// just set client mesh pointer to server mesh pointer
//SMESH_Mesh* aMesh = reinterpret_cast<SMESH_Mesh*>(theMesh->GetMeshPtr());
CORBA::LongLong pointeur = theMesh->GetMeshPtr();
- if( MYDEBUG )
- MESSAGE("SMESH_Client::SMESH_Client pointeur "<<pointeur);
+ if( MYDEBUG ) MESSAGE("SMESH_Client::SMESH_Client pointeur "<<pointeur);
SMESH_Mesh* aMesh = reinterpret_cast<SMESH_Mesh*> (pointeur);
SMESH_Mesh* aMesh = reinterpret_cast<SMESH_Mesh*> (pointeur);
- if ( MYDEBUG )
- MESSAGE("SMESH_Client::SMESH_Client aMesh "<<aMesh);
+ if ( MYDEBUG ) MESSAGE("SMESH_Client::SMESH_Client aMesh "<<aMesh);
//if(aMesh->GetMeshDS()->IsEmbeddedMode()){
if(anIsEmbeddedMode){
mySMESHDSMesh = aMesh->GetMeshDS();
//if(aMesh->GetMeshDS()->IsEmbeddedMode()){
if(anIsEmbeddedMode){
mySMESHDSMesh = aMesh->GetMeshDS();
@@
-886,20
+897,22
@@
bool
SMESH_Client::Update(bool theIsClear)
{
bool anIsModified = true;
SMESH_Client::Update(bool theIsClear)
{
bool anIsModified = true;
- if(mySMESHDSMesh){
- MESSAGE("Update mySMESHDSMesh");
+ if(mySMESHDSMesh)
+ {
+ if ( MYDEBUG ) MESSAGE("Update mySMESHDSMesh");
SMESHDS_Script* aScript = mySMESHDSMesh->GetScript();
anIsModified = aScript->IsModified();
aScript->SetModified(false);
SMESHDS_Script* aScript = mySMESHDSMesh->GetScript();
anIsModified = aScript->IsModified();
aScript->SetModified(false);
- }else{
- MESSAGE("Update CORBA");
+ }
+ else
+ {
+ if ( MYDEBUG ) MESSAGE("Update CORBA");
SMESH::log_array_var aSeq = myMeshServer->GetLog( theIsClear );
CORBA::Long aLength = aSeq->length();
anIsModified = aLength > 0;
SMESH::log_array_var aSeq = myMeshServer->GetLog( theIsClear );
CORBA::Long aLength = aSeq->length();
anIsModified = aLength > 0;
- if( MYDEBUG )
- MESSAGE( "Update: length of the script is "<<aLength );
+ if ( MYDEBUG ) MESSAGE( "Update: length of the script is "<<aLength );
- if
(!anIsModified
)
+ if
( !anIsModified
)
return false;
// update client mesh structure by logged changes commands
return false;
// update client mesh structure by logged changes commands
@@
-985,10
+998,10
@@
SMESH_Client::Update(bool theIsClear)
ChangePolyhedronNodes(mySMDSMesh, aSeq, anId);
break;
case SMESH::RENUMBER:
ChangePolyhedronNodes(mySMDSMesh, aSeq, anId);
break;
case SMESH::RENUMBER:
- for(CORBA::Long i=0; anElemId < aNbElems; anElemId++, i+=3)
- {
- mySMDSMesh->Renumber( anIndexes[i], anIndexes[i+1], anIndexes[i+2] );
- }
+
//
for(CORBA::Long i=0; anElemId < aNbElems; anElemId++, i+=3)
+
//
{
+
//
mySMDSMesh->Renumber( anIndexes[i], anIndexes[i+1], anIndexes[i+2] );
+
//
}
break;
default:;
break;
default:;