Salome HOME
Add method AddBoundary to idl interface HOMARD_Gen
[modules/smesh.git] / src / SMESH_I / SMESH_Homard_i.cxx
index c5d5a8fb837716dbcb629513cc05a40ff68d4f37..55699404a176729de876f15b09ff1e6c782383fd 100644 (file)
@@ -2493,6 +2493,19 @@ void HOMARD_Gen_i::PythonDump()
   MESSAGE ("End PythonDump");
 }
 
+void HOMARD_Gen_i::AddBoundary(const char* BoundaryName)
+{
+  MESSAGE("HOMARD_Gen_i::AddBoundary : BoundaryName = " << BoundaryName);
+  if (myCase->_is_nil()) {
+    SALOME::ExceptionStruct es;
+    es.type = SALOME::BAD_PARAM;
+    std::string text = "The input mesh must be defined before boundary addition";
+    es.text = CORBA::string_dup(text.c_str());
+    throw SALOME::SALOME_Exception(es);
+  }
+  myCase->AddBoundary(BoundaryName);
+}
+
 void HOMARD_Gen_i::AddBoundaryGroup(const char* BoundaryName, const char* Group)
 {
   MESSAGE("HOMARD_Gen_i::AddBoundaryGroup : BoundaryName = " <<