Salome HOME
updated copyright message
[plugins/gmshplugin.git] / src / GMSHPlugin / GMSHPlugin_Hypothesis_i.cxx
index 312b762cf72141b484caed213e8c915039da214d..036fdc9489d97861881651f7311189eba318ca3f 100644 (file)
@@ -1,10 +1,10 @@
 // Copyright (C) 2012-2015  ALNEOS
-// Copyright (C) 2016  EDF R&D
+// Copyright (C) 2016-2023  EDF
 //
 // 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.
+// version 2.1 of the License, or (at your option) any later version.
 //
 // This library is distributed in the hope that it will be useful,
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -16,6 +16,7 @@
 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
 //
 // See http://www.alneos.com/ or email : contact@alneos.fr
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
 //
 #include "GMSHPlugin_Hypothesis_i.hxx"
 #include "SMESH_Gen.hxx"
@@ -66,6 +67,22 @@ CORBA::Double GMSHPlugin_Hypothesis_i::GetMaxSize()
   return this->GetImpl()->GetMaxSize();
 }
 
+
+void GMSHPlugin_Hypothesis_i::SetMeshCurvatureSize (CORBA::Double theMeshCurvatureSize)
+{
+  if ( isToSetParameter( GetMeshCurvatureSize(), theMeshCurvatureSize, METH_SetMeshCurvatureSize ))
+  {
+    this->GetImpl()->SetMeshCurvatureSize(theMeshCurvatureSize);
+    SMESH::TPythonDump() << _this() << ".SetMeshCurvatureSize( " << SMESH::TVar(theMeshCurvatureSize) << " )";
+  }
+}
+
+CORBA::Double GMSHPlugin_Hypothesis_i::GetMeshCurvatureSize()
+{
+  return this->GetImpl()->GetMeshCurvatureSize();
+}
+
+
 void GMSHPlugin_Hypothesis_i::SetMinSize (CORBA::Double theValue)
 {
   if ( isToSetParameter( GetMinSize(), theValue, METH_SetMinSize ))
@@ -318,6 +335,7 @@ int GMSHPlugin_Hypothesis_i::getParamIndex(const TCollection_AsciiString& method
   if ( method == "SetNbSegPerEdge"   ) return 2;
   if ( method == "SetNbSegPerRadius" ) return 3;
   if ( method == "SetMinSize" )        return nbVars-1;
+  if ( method == "SetMeshCurvatureSize" )        return 5;
 
   return SMESH_Hypothesis_i::getParamIndex( method, nbVars ); // return default value
 }
@@ -339,6 +357,7 @@ std::string GMSHPlugin_Hypothesis_i::getMethodOfParameter(const int paramIndex,
   case 2: return "SetNbSegPerEdge";
   case 3: return "SetNbSegPerRadius";
   case 4: return "SetMinSize";
+  case 5: return "SetMeshCurvatureSize";
   }
   return "";
 }
@@ -351,7 +370,7 @@ std::string GMSHPlugin_Hypothesis_i::getMethodOfParameter(const int paramIndex,
 
 bool
 GMSHPlugin_Hypothesis_i::getObjectsDependOn( std::vector< std::string > & entryArray,
-                                             std::vector< int >         & subIDArray ) const
+                                             std::vector< int >         & /*subIDArray*/ ) const
 {
   typedef ::GMSHPlugin_Hypothesis THyp;
   const THyp* impl = static_cast<const THyp*>( myBaseImpl );
@@ -370,7 +389,7 @@ GMSHPlugin_Hypothesis_i::getObjectsDependOn( std::vector< std::string > & entryA
 
 bool
 GMSHPlugin_Hypothesis_i::setObjectsDependOn( std::vector< std::string > & entryArray,
-                                             std::vector< int >         & subIDArray )
+                                             std::vector< int >         & /*subIDArray*/ )
 {
   typedef ::GMSHPlugin_Hypothesis THyp;
   THyp* impl = static_cast< THyp* >( myBaseImpl );