X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;ds=sidebyside;f=doc%2Fsalome%2Fgui%2FSMESH%2Fcollect_mesh_methods.py;h=da53d4ee664ee6afb9f162bc1dd5e1e58a57d382;hb=442fd64c19a6e27a339ca36264c15ec91732cf32;hp=7aa83b0849f15c5ed13eee0345671303feb711ed;hpb=c98d9fcd7f02c1f1f5c24dd3e709ed75228d66c4;p=modules%2Fsmesh.git diff --git a/doc/salome/gui/SMESH/collect_mesh_methods.py b/doc/salome/gui/SMESH/collect_mesh_methods.py index 7aa83b084..da53d4ee6 100755 --- a/doc/salome/gui/SMESH/collect_mesh_methods.py +++ b/doc/salome/gui/SMESH/collect_mesh_methods.py @@ -31,7 +31,7 @@ # class. # # This script is intended for internal usage - only -# for generatation of the extra developer documentation for +# for generation of the extra developer documentation for # the meshing plug-in(s). # # Usage: @@ -46,6 +46,7 @@ # ################################################################################ +import inspect import sys def main(plugin_name, dummymeshhelp = True, output_file = "smeshBuilder.py"): @@ -59,7 +60,7 @@ def main(plugin_name, dummymeshhelp = True, output_file = "smeshBuilder.py"): for attr in dir( mod ): if attr.startswith( '_' ): continue algo = getattr( mod, attr ) - if type( algo ).__name__ == 'classobj' and hasattr( algo, "meshMethod" ): + if inspect.isclass(algo) and hasattr(algo, "meshMethod"): method = getattr( algo, "meshMethod" ) if method not in methods: methods[ method ] = [] methods[ method ].append( algo ) @@ -116,8 +117,8 @@ def main(plugin_name, dummymeshhelp = True, output_file = "smeshBuilder.py"): f.close() pass pass - except Exception, e: - print e + except Exception as e: + print(e) pass pass