From b84df6a59fd4366dfc316dc1b7d76b0f3f7286b6 Mon Sep 17 00:00:00 2001 From: nri Date: Thu, 10 Jul 2003 15:27:52 +0000 Subject: [PATCH] NRI : Merge from V1_2. --- src/Makefile.in | 33 ++++++++---- src/MedCorba_Swig/Makefile.in | 32 ++++++++--- src/MedCorba_Swig/batchmode_medcorba_test.py | 9 ++++ src/MedCorba_Swig/medcorba_test.py | 26 +++++++++ src/MedMem/Family_i.cxx | 36 ++++++++++--- src/MedMem/FieldDouble_i.cxx | 38 +++++++++---- src/MedMem/FieldInt_i.cxx | 38 +++++++++---- src/MedMem/FieldOf_i.hxx | 39 ++++++++++---- src/MedMem/Field_i.cxx | 36 ++++++++++--- src/MedMem/Group_i.cxx | 36 ++++++++++--- src/MedMem/Makefile.in | 36 ++++++++++--- src/MedMem/Med_i.cxx | 36 ++++++++++--- src/MedMem/Mesh_i.cxx | 56 +++++++++++++------- src/MedMem/Support_i.cxx | 42 +++++++++++---- src/MedMem/convert.cxx | 37 +++++++++---- 15 files changed, 409 insertions(+), 121 deletions(-) diff --git a/src/Makefile.in b/src/Makefile.in index ffdf337a4..3c7d5d725 100644 --- a/src/Makefile.in +++ b/src/Makefile.in @@ -1,13 +1,29 @@ -#============================================================================== -# File : Makefile.in -# Created : ven déc 7 13:32:20 CET 2001 -# Author : Paul RASCLE, EDF -# Project : SALOME -# Copyright : EDF 2001 +# Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, +# CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS +# +# This library is free software; you can redistribute it and/or +# modify it under the terms of the GNU Lesser General Public +# License as published by the Free Software Foundation; either +# version 2.1 of the License. +# +# This library is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# Lesser General Public License for more details. +# +# You should have received a copy of the GNU Lesser General Public +# 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 +# +# +# +# File : Makefile.in +# Author : Paul RASCLE, EDF +# Module : MED # $Header$ -#============================================================================== -# source path top_srcdir=@top_srcdir@ top_builddir=.. srcdir=@srcdir@ @@ -16,6 +32,5 @@ VPATH=.:@srcdir@ @COMMENCE@ SUBDIRS = MEDMEM MEDMEM_SWIG MedMem MED MEDGUI MedCorba_Swig -#SUBDIRS = MEDMEM MEDMEM_SWIG MedMem MED MedCorba_Swig @MODULE@ diff --git a/src/MedCorba_Swig/Makefile.in b/src/MedCorba_Swig/Makefile.in index ead5fa987..9cb1be44e 100644 --- a/src/MedCorba_Swig/Makefile.in +++ b/src/MedCorba_Swig/Makefile.in @@ -1,10 +1,30 @@ -#============================================================================== -# File : Makefile.in -# Author : Nadir BOUHAMOU (CEA/DEN/DM2S/SFME/LGLS) -# CVS : $Header$ -#============================================================================== +# MED MedCorba_Swig : binding of MED CORBA objects woth Python +# +# Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, +# CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS +# +# This library is free software; you can redistribute it and/or +# modify it under the terms of the GNU Lesser General Public +# License as published by the Free Software Foundation; either +# version 2.1 of the License. +# +# This library is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# Lesser General Public License for more details. +# +# You should have received a copy of the GNU Lesser General Public +# 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 +# +# +# +# File : Makefile.in +# Author : Nadir BOUHAMOU (CEA/DEN/DM2S/SFME/LGLS) +# Module : MED -# source path top_srcdir=@top_srcdir@ top_builddir=../.. srcdir=@srcdir@ diff --git a/src/MedCorba_Swig/batchmode_medcorba_test.py b/src/MedCorba_Swig/batchmode_medcorba_test.py index ad1373cf2..2b2877259 100755 --- a/src/MedCorba_Swig/batchmode_medcorba_test.py +++ b/src/MedCorba_Swig/batchmode_medcorba_test.py @@ -1,3 +1,12 @@ +# MED MedCorba_Swig : binding of MED CORBA objects woth Python +# +# Copyright (C) 2003 CEA/DEN, EDF R&D +# +# +# +# File : batchmode_medcorba_test.py +# Module : MED + import batchmode_salome import SALOME_MED diff --git a/src/MedCorba_Swig/medcorba_test.py b/src/MedCorba_Swig/medcorba_test.py index 4961487cb..46a45ea96 100644 --- a/src/MedCorba_Swig/medcorba_test.py +++ b/src/MedCorba_Swig/medcorba_test.py @@ -1,3 +1,29 @@ +# MED MedCorba_Swig : binding of MED CORBA objects woth Python +# +# Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, +# CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS +# +# This library is free software; you can redistribute it and/or +# modify it under the terms of the GNU Lesser General Public +# License as published by the Free Software Foundation; either +# version 2.1 of the License. +# +# This library is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# Lesser General Public License for more details. +# +# You should have received a copy of the GNU Lesser General Public +# 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 +# +# +# +# File : medcorba_test.py +# Module : MED + import salome import SALOME_MED diff --git a/src/MedMem/Family_i.cxx b/src/MedMem/Family_i.cxx index 3715207e1..81d51782a 100644 --- a/src/MedMem/Family_i.cxx +++ b/src/MedMem/Family_i.cxx @@ -1,12 +1,32 @@ -using namespace std; -//============================================================================= -// File : Family_i.cxx -// Project : SALOME -// Copyright : EDF 2002 -// Author : EDF -// $Header: /export/home/CVS/SALOME_ROOT/MED/src/MedMem/Family_i.cxx -//============================================================================= +// MED MedMem : MED idl descriptions implementation based on the classes of MEDMEM +// +// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, +// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS +// +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public +// License as published by the Free Software Foundation; either +// version 2.1 of the License. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// 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 +// +// +// +// File : Family_i.cxx +// Author : EDF +// Module : MED +// $Header: /export/home/CVS/SALOME_ROOT/MED/src/MedMem/Family_i.cxx +using namespace std; #include "Family_i.hxx" #include "utilities.h" diff --git a/src/MedMem/FieldDouble_i.cxx b/src/MedMem/FieldDouble_i.cxx index bdbea873e..d44257488 100644 --- a/src/MedMem/FieldDouble_i.cxx +++ b/src/MedMem/FieldDouble_i.cxx @@ -1,12 +1,32 @@ -using namespace std; -//============================================================================= -// File : Fielddouble_i.hxx -// Project : SALOME -// Author : EDF -// Copyright : EDF 2002 -// $Header: /export/home/CVS/SALOME_ROOT/MED/src/MedMem/Fielddouble_i.hxx -//============================================================================= +// MED MedMem : MED idl descriptions implementation based on the classes of MEDMEM +// +// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, +// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS +// +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public +// License as published by the Free Software Foundation; either +// version 2.1 of the License. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// 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 +// +// +// +// File : Fielddouble_i.hxx +// Author : EDF +// Module : MED +// $Header: /export/home/CVS/SALOME_ROOT/MED/src/MedMem/Fielddouble_i.hxx +using namespace std; #include "FieldDouble_i.hxx" #include "utilities.h" #include "convert.hxx" @@ -85,7 +105,7 @@ throw (SALOME::SALOME_Exception) } medModeSwitch modemed=convertIdlModeToMedMode(mode); - double * values =_fieldTptr->getValue(modemed); + const double * values =_fieldTptr->getValue(modemed); myseq->length(nbval); for (int i=0; igetValue(modemed); + const int * values =_fieldTptr->getValue(modemed); myseq->length(nbval); for (int i=0; igetNumberOfComponents(); myseq->length(nbcom); - string * namecom=_fieldTptr->getComponentsNames(); + const string * namecom=_fieldTptr->getComponentsNames(); for (int i=0;igetNumberOfComponents(); myseq->length(nbcom); - string * unitcom=_fieldTptr->getMEDComponentsUnits(); + const string * unitcom=_fieldTptr->getMEDComponentsUnits(); for (int i=0;i #include "utilities.h" diff --git a/src/MedMem/Makefile.in b/src/MedMem/Makefile.in index 319498e6c..d7144451a 100644 --- a/src/MedMem/Makefile.in +++ b/src/MedMem/Makefile.in @@ -1,11 +1,31 @@ -#============================================================================== -// File : Field_i.hxx -// Author : Marc Tajchman -// Project : SALOME -// $Header: /export/home/CVS/SALOME_ROOT/MED/src/MedMem/Makefile.in -//============================================================================= - -# source path +# MED MedMem : MED idl descriptions implementation based on the classes of MEDMEM +# +# Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, +# CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS +# +# This library is free software; you can redistribute it and/or +# modify it under the terms of the GNU Lesser General Public +# License as published by the Free Software Foundation; either +# version 2.1 of the License. +# +# This library is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# Lesser General Public License for more details. +# +# You should have received a copy of the GNU Lesser General Public +# 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 +# +# +# +# File : Field_i.hxx +# Author : Marc Tajchman +# Module : MED +# $Header: /export/home/CVS/SALOME_ROOT/MED/src/MedMem/Makefile.in + top_srcdir=@top_srcdir@ top_builddir=../.. srcdir=@srcdir@ diff --git a/src/MedMem/Med_i.cxx b/src/MedMem/Med_i.cxx index 3c0830489..b3be89ac8 100644 --- a/src/MedMem/Med_i.cxx +++ b/src/MedMem/Med_i.cxx @@ -1,12 +1,32 @@ -using namespace std; -//============================================================================= -// File : Med_i.cxx -// Project : SALOME -// Author : EDF -// Copyright : EDF 2002 -// $Header: /export/home/CVS/SALOME_ROOT/MED/src/MedMem/Med_i.cxx -//============================================================================= +// MED MedMem : MED idl descriptions implementation based on the classes of MEDMEM +// +// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, +// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS +// +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public +// License as published by the Free Software Foundation; either +// version 2.1 of the License. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// 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 +// +// +// +// File : Med_i.cxx +// Author : EDF +// Module : MED +// $Header: /export/home/CVS/SALOME_ROOT/MED/src/MedMem/Med_i.cxx +using namespace std; #include //#include "MEDMEM_Field.hxx" diff --git a/src/MedMem/Mesh_i.cxx b/src/MedMem/Mesh_i.cxx index 881dd2bd4..b32dbce0f 100644 --- a/src/MedMem/Mesh_i.cxx +++ b/src/MedMem/Mesh_i.cxx @@ -1,12 +1,32 @@ -using namespace std; -//============================================================================= -// File : Mesh_i.cxx -// Project : SALOME -// Author : EDF -// Copyright : EDF 2002 -// $Header: /export/home/CVS/SALOME_ROOT/MED/src/MedMem/Mesh_i.cxx -//============================================================================= +// MED MedMem : MED idl descriptions implementation based on the classes of MEDMEM +// +// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, +// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS +// +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public +// License as published by the Free Software Foundation; either +// version 2.1 of the License. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// 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 +// +// +// +// File : Mesh_i.cxx +// Author : EDF +// Module : MED +// $Header: /export/home/CVS/SALOME_ROOT/MED/src/MedMem/Mesh_i.cxx +using namespace std; #include #include "utilities.h" @@ -244,7 +264,7 @@ throw (SALOME::SALOME_Exception) try { int spaceDimension=_mesh->getSpaceDimension(); - string * coordinatesName =_mesh->getCoordinatesNames(); + const string * coordinatesName =_mesh->getCoordinatesNames(); myseq->length(spaceDimension); for (int i=0; igetSpaceDimension(); - string * coordinatesUnits =_mesh->getCoordinatesUnits(); + const string * coordinatesUnits =_mesh->getCoordinatesUnits(); myseq->length(spaceDimension); for (int i=0; igetNumberOfTypes(convertIdlEntToMedEnt(entity)); - medGeometryElement * elemts =_mesh->getTypes( + const medGeometryElement * elemts =_mesh->getTypes( convertIdlEntToMedEnt(entity)); myseq->length(nbTypes); for (int i=0; igetConnectivityIndex( + const int * tab=_mesh->getConnectivityIndex( convertIdlConnToMedConn(mode), convertIdlEntToMedEnt(entity)); nbelements = elt1*(convertIdlEltToMedElt(geomElement)%100); @@ -447,7 +467,7 @@ SCRUTE(entity); SCRUTE(geomElement); SCRUTE(nbelements); myseq->length(nbelements); - int * numbers=_mesh->getConnectivity(convertIdlModeToMedMode(typeSwitch), + const int * numbers=_mesh->getConnectivity(convertIdlModeToMedMode(typeSwitch), convertIdlConnToMedConn(mode), convertIdlEntToMedEnt(entity), convertIdlEltToMedElt(geomElement)); @@ -483,7 +503,7 @@ throw (SALOME::SALOME_Exception) convertIdlEntToMedEnt(entity), MED_ALL_ELEMENTS); myseq->length(nbelements); - int * numbers=_mesh->getConnectivityIndex(convertIdlConnToMedConn(mode), + const int * numbers=_mesh->getConnectivityIndex(convertIdlConnToMedConn(mode), convertIdlEntToMedEnt(entity)); for (int i=0;ilength(nbelements); - int * numbers=_mesh->getReverseConnectivity(convertIdlConnToMedConn(mode)); + const int * numbers=_mesh->getReverseConnectivity(convertIdlConnToMedConn(mode)); for (int i=0;ilength(nbelements); - int * numbers=_mesh->getReverseConnectivityIndex(convertIdlConnToMedConn(mode)); + const int * numbers=_mesh->getReverseConnectivityIndex(convertIdlConnToMedConn(mode)); for (int i=0;igetFamily(convertIdlEntToMedEnt(entity),i); + const FAMILY * fam = _mesh->getFamily(convertIdlEntToMedEnt(entity),i); FAMILY_i * f1=new FAMILY_i(fam); SALOME_MED::FAMILY_ptr f2 = f1->POA_SALOME_MED::FAMILY::_this(); f1->_remove_ref(); @@ -773,7 +793,7 @@ throw (SALOME::SALOME_Exception) SALOME::INTERNAL_ERROR); try { - GROUP * grou = _mesh->getGroup(convertIdlEntToMedEnt(entity),i); + const GROUP * grou = _mesh->getGroup(convertIdlEntToMedEnt(entity),i); GROUP_i * f1=new GROUP_i(grou); SALOME_MED::GROUP_ptr f2 = f1->POA_SALOME_MED::GROUP::_this(); f1->_remove_ref(); diff --git a/src/MedMem/Support_i.cxx b/src/MedMem/Support_i.cxx index 0804a3f9a..ea1d9b39a 100644 --- a/src/MedMem/Support_i.cxx +++ b/src/MedMem/Support_i.cxx @@ -1,12 +1,32 @@ -using namespace std; -//============================================================================= -// File : Support_i.cxx -// Project : SALOME -// Author : EDF -// Copyright : EDF 2002 -// $Header: /export/home/CVS/SALOME_ROOT/MED/src/MedMem/Support_i.cxx -//============================================================================= +// MED MedMem : MED idl descriptions implementation based on the classes of MEDMEM +// +// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, +// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS +// +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public +// License as published by the Free Software Foundation; either +// version 2.1 of the License. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// 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 +// +// +// +// File : Support_i.cxx +// Author : EDF +// Module : MED +// $Header: /export/home/CVS/SALOME_ROOT/MED/src/MedMem/Support_i.cxx +using namespace std; #include "utilities.h" #include "Utils_CorbaException.hxx" #include "Utils_ORB_INIT.hxx" @@ -248,7 +268,7 @@ throw (SALOME::SALOME_Exception) { int mySeqLength=_support->getNumberOfTypes(); myseq->length(mySeqLength); - medGeometryElement * elemts = _support->getTypes(); + const medGeometryElement * elemts = _support->getTypes(); for (int i=0;igetName()); SCRUTE(nbelements); SCRUTE(convertIdlEltToMedElt(geomElement)); - int * numbers=_support->getNumber(convertIdlEltToMedElt(geomElement)); + const int * numbers=_support->getNumber(convertIdlEltToMedElt(geomElement)); for (int i=0;igetNumberOfElements(::MED_ALL_ELEMENTS); myseq->length(nbelements); - int * numbers=_support->getNumberIndex(); + const int * numbers=_support->getNumberIndex(); for (int i=0;i