Salome HOME
PAL18328 SMESH_AdvancedEditor.py don't work in Debug version
authoreap <eap@opencascade.com>
Tue, 18 Dec 2007 11:54:04 +0000 (11:54 +0000)
committereap <eap@opencascade.com>
Tue, 18 Dec 2007 11:54:04 +0000 (11:54 +0000)
-class SMDS_WNT_EXPORT SMDS_VolumeTool
+class SMDS_EXPORT SMDS_VolumeTool
 {
  public:
+  const SMDS_MeshVolume* Get() const;
+  // return element
+
+  int ID() const;
+  // return element ID

src/SMDS/SMDS_VolumeTool.cxx
src/SMDS/SMDS_VolumeTool.hxx
src/SMDS/SMESH_SMDS.hxx [new file with mode: 0755]

index 592e79eb9dda4a995ec0be25915c395c2a71be7e..3094a761f0cff2aa5f60af6c802450b42ec4b6a0 100644 (file)
@@ -1651,3 +1651,22 @@ int SMDS_VolumeTool::NbFaceNodes(VolumeType type,
   return 0;
 }
 
+//=======================================================================
+//function : Get
+//purpose  : return element
+//=======================================================================
+
+const SMDS_MeshVolume* SMDS_VolumeTool::Get() const
+{
+  return static_cast<const SMDS_MeshVolume*>( myVolume );
+}
+
+//=======================================================================
+//function : ID
+//purpose  : return element ID
+//=======================================================================
+
+int SMDS_VolumeTool::ID() const
+{
+  return myVolume ? myVolume->GetID() : 0;
+}
index 18aa6aec3173caf7e1774ff01a5147ef155f6b72..5eb5a0755a5012460bffbb485b7ef60e380b5495 100644 (file)
 #ifndef SMDS_VolumeTool_HeaderFile
 #define SMDS_VolumeTool_HeaderFile
 
+#include "SMESH_SMDS.hxx"
+
 class SMDS_MeshElement;
 class SMDS_MeshNode;
 class SMDS_PolyhedralVolumeOfNodes;
+class SMDS_MeshVolume;
 
 #include <vector>
 #include <set>
 
-//#ifdef WNT
-//#include <SALOME_WNT.hxx>
-//#else
-//#define SALOME_WNT_EXPORT
-//#endif
-
-#if defined WNT && defined WIN32 && defined SMDS_EXPORTS
-#define SMDS_WNT_EXPORT __declspec( dllexport )
-#else
-#define SMDS_WNT_EXPORT
-#endif
-
 // =========================================================================
 //
 // Class providing topological and other information about SMDS_MeshVolume:
@@ -57,7 +48,7 @@ class SMDS_PolyhedralVolumeOfNodes;
 //
 // =========================================================================
 
-class SMDS_WNT_EXPORT SMDS_VolumeTool
+class SMDS_EXPORT SMDS_VolumeTool
 {
  public:
 
@@ -72,6 +63,12 @@ class SMDS_WNT_EXPORT SMDS_VolumeTool
   // Set volume.
   // Return false if theVolume is not of type SMDSAbs_Volume
 
+  const SMDS_MeshVolume* Get() const;
+  // return element
+
+  int ID() const;
+  // return element ID
+
   // -----------------------
   // general info
   // -----------------------
diff --git a/src/SMDS/SMESH_SMDS.hxx b/src/SMDS/SMESH_SMDS.hxx
new file mode 100755 (executable)
index 0000000..d354e13
--- /dev/null
@@ -0,0 +1,39 @@
+//  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   : SMESH_SMDS.hxx
+//  Author : Alexander A. BORODIN
+//  Module : SMESH
+
+#ifndef _SMESH_SMDS_HXX_
+#define _SMESH_SMDS_HXX_
+
+#ifdef WNT
+ #if defined SMDS_EXPORTS
+  #define SMDS_EXPORT __declspec( dllexport )
+ #else
+  #define SMDS_EXPORT __declspec( dllimport )
+ #endif
+#else
+ #define SMDS_EXPORT
+#endif
+
+#endif