]> SALOME platform Git repositories - modules/shaper.git/commitdiff
Salome HOME
roots use tools
authorspo <sergey.pokhodenko@opencascade.com>
Mon, 26 Oct 2015 11:23:12 +0000 (14:23 +0300)
committerspo <sergey.pokhodenko@opencascade.com>
Mon, 26 Oct 2015 11:23:12 +0000 (14:23 +0300)
src/PythonAPI/model/roots.py

index b5d05f559f01dd02c1fe30e728d1834de9c38e63..798f4dac388bce30f7de459b30e0347d14d7504c 100644 (file)
@@ -5,7 +5,7 @@ Copyright (C) 2014-20xx CEA/DEN, EDF R&D
 
 import ModelAPI
 
-from .tools import get_value, convert_to_underscore
+from model import tools
 
 
 class Feature(ModelAPI.ModelAPI_Feature):
@@ -46,7 +46,7 @@ class Interface():
         if name.startswith("get"):
             possible_names = [
                 "_" + name[3:],
-                "_" + convert_to_underscore(name[3:]),
+                "_" + tools.convert_to_underscore(name[3:]),
                 ]
             for possible_name in possible_names:
                 if hasattr(self, possible_name):
@@ -63,6 +63,10 @@ class Interface():
         """Return ModelAPI_Feature."""
         return self._feature
 
+    def _fill_attribute(self, attribute, value, *args):
+        """Fill ModelAPI_Attribute* with value."""
+        tools.fill_attribute(attribute, value, *args)
+
     def setRealInput(self, inputid, value):
         self._feature.data().real(inputid).setValue(value)