From: vsr Date: Thu, 8 Oct 2020 14:27:17 +0000 (+0300) Subject: #19896 [CEA] GHS3DPlugin_Hypothesis' object has no attribute 'SetPrintLogInFile' X-Git-Tag: V9_6_0a2 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=88c02abb06e3d056199031bac8a0deb2f1184979;p=plugins%2Fghs3dplugin.git #19896 [CEA] GHS3DPlugin_Hypothesis' object has no attribute 'SetPrintLogInFile' keep backward compatibility with deprecated API --- diff --git a/src/GHS3DPlugin/GHS3DPluginBuilder.py b/src/GHS3DPlugin/GHS3DPluginBuilder.py index 8beb2c0..35bb8b7 100644 --- a/src/GHS3DPlugin/GHS3DPluginBuilder.py +++ b/src/GHS3DPlugin/GHS3DPluginBuilder.py @@ -21,6 +21,7 @@ # @package GHS3DPluginBuilder # Python API for the MG-Tetra meshing plug-in module. +import omniORB from salome.smesh.smesh_algorithm import Mesh_Algorithm from salome.smesh.smeshBuilder import AssureGeomPublished @@ -474,3 +475,17 @@ class GHS3D_Optimizer(GHS3D_Algorithm): pass pass # end of GHS3D_Optimizer class + +class hypoProxy(GHS3DPlugin._objref_GHS3DPlugin_Hypothesis): + """ + Private class wrapping to provide backward compatibility with deprecated API. + """ + def __init__(self, *args): + GHS3DPlugin._objref_GHS3DPlugin_Hypothesis.__init__(self, *args) + def __deepcopy__(self, memo=None): + new = self.__class__(self) + return new + def SetPrintLogInFile(self, value): + self.SetStandardOutputLog(not value) +omniORB.registerObjref(GHS3DPlugin._objref_GHS3DPlugin_Hypothesis._NP_RepositoryId, hypoProxy) +del hypoProxy