From c41c16260a8dfe66352f946e741cba6e882e1772 Mon Sep 17 00:00:00 2001 From: rahuel Date: Fri, 5 Nov 2004 08:36:38 +0000 Subject: [PATCH] new configure option : --without-ihm (default with-ihm) --- src/SALOME_SWIG/Makefile.in | 6 +- .../Help.py | 0 src/SALOME_SWIG_WITHOUTIHM/Makefile.in | 52 +++++ .../PyInterp.py | 0 .../batchmode_salome.py | 219 ++++++++++++++++++ .../examplevtk1.py | 0 .../import_hook.py | 0 .../kernel_shared_modules.py | 4 + .../salome.py | 0 .../salome_shared_modules.py | 0 .../salome_test.py | 0 .../supervisionexample.py.in | 85 +++++++ .../supervisiongeomexample.py.in | 103 ++++++++ .../test_big_table.py | 0 .../test_many_objects.py | 0 .../test_table.py | 0 .../testattr.py | 0 17 files changed, 467 insertions(+), 2 deletions(-) rename src/{SALOME_SWIG => SALOME_SWIG_WITHOUTIHM}/Help.py (100%) mode change 100644 => 100755 create mode 100755 src/SALOME_SWIG_WITHOUTIHM/Makefile.in rename src/{SALOME_SWIG => SALOME_SWIG_WITHOUTIHM}/PyInterp.py (100%) mode change 100644 => 100755 create mode 100755 src/SALOME_SWIG_WITHOUTIHM/batchmode_salome.py rename src/{SALOME_SWIG => SALOME_SWIG_WITHOUTIHM}/examplevtk1.py (100%) mode change 100644 => 100755 rename src/{SALOME_SWIG => SALOME_SWIG_WITHOUTIHM}/import_hook.py (100%) mode change 100644 => 100755 rename src/{SALOME_SWIG => SALOME_SWIG_WITHOUTIHM}/kernel_shared_modules.py (96%) mode change 100644 => 100755 rename src/{SALOME_SWIG => SALOME_SWIG_WITHOUTIHM}/salome.py (100%) mode change 100644 => 100755 rename src/{SALOME_SWIG => SALOME_SWIG_WITHOUTIHM}/salome_shared_modules.py (100%) mode change 100644 => 100755 rename src/{SALOME_SWIG => SALOME_SWIG_WITHOUTIHM}/salome_test.py (100%) mode change 100644 => 100755 create mode 100755 src/SALOME_SWIG_WITHOUTIHM/supervisionexample.py.in create mode 100755 src/SALOME_SWIG_WITHOUTIHM/supervisiongeomexample.py.in rename src/{SALOME_SWIG => SALOME_SWIG_WITHOUTIHM}/test_big_table.py (100%) mode change 100644 => 100755 rename src/{SALOME_SWIG => SALOME_SWIG_WITHOUTIHM}/test_many_objects.py (100%) mode change 100644 => 100755 rename src/{SALOME_SWIG => SALOME_SWIG_WITHOUTIHM}/test_table.py (100%) mode change 100644 => 100755 rename src/{SALOME_SWIG => SALOME_SWIG_WITHOUTIHM}/testattr.py (100%) mode change 100644 => 100755 diff --git a/src/SALOME_SWIG/Makefile.in b/src/SALOME_SWIG/Makefile.in index ddd2ccfbd..08640e24c 100644 --- a/src/SALOME_SWIG/Makefile.in +++ b/src/SALOME_SWIG/Makefile.in @@ -38,9 +38,11 @@ LIB = libSALOME_Swigcmodule.la LIB_SRC = SWIG_DEF = libSALOME_Swig.i -EXPORT_PYSCRIPTS = libSALOME_Swig.py Help.py PyInterp.py salome.py examplevtk1.py supervisionexample.py supervisiongeomexample.py salome_shared_modules.py batchmode_salome.py test_table.py test_big_table.py test_many_objects.py import_hook.py salome_test.py +#EXPORT_PYSCRIPTS = libSALOME_Swig.py Help.py PyInterp.py salome.py examplevtk1.py supervisionexample.py supervisiongeomexample.py salome_shared_modules.py batchmode_salome.py test_table.py test_big_table.py test_many_objects.py import_hook.py salome_test.py -EXPORT_SHAREDPYSCRIPTS=kernel_shared_modules.py +EXPORT_PYSCRIPTS = libSALOME_Swig.py batchmode_salome.py + +#EXPORT_SHAREDPYSCRIPTS=kernel_shared_modules.py LIB_CLIENT_IDL = SALOMEDS.idl \ SALOME_Exception.idl diff --git a/src/SALOME_SWIG/Help.py b/src/SALOME_SWIG_WITHOUTIHM/Help.py old mode 100644 new mode 100755 similarity index 100% rename from src/SALOME_SWIG/Help.py rename to src/SALOME_SWIG_WITHOUTIHM/Help.py diff --git a/src/SALOME_SWIG_WITHOUTIHM/Makefile.in b/src/SALOME_SWIG_WITHOUTIHM/Makefile.in new file mode 100755 index 000000000..1c42c1ad6 --- /dev/null +++ b/src/SALOME_SWIG_WITHOUTIHM/Makefile.in @@ -0,0 +1,52 @@ +# Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, +# CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS +# +# 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. +# +# This library is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# Lesser General Public License for more details. +# +# You should have received a copy of the GNU Lesser General Public +# License along with this library; if not, write to the Free Software +# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +# +# See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org +# +# +# +# File : Makefile.in +# Author : Paul RASCLE, EDF +# Module : SALOME +# $Header$ + +top_srcdir=@top_srcdir@ +top_builddir=../.. +srcdir=@srcdir@ +VPATH=.:@srcdir@:@top_srcdir@/idl + + +@COMMENCE@ + +# Libraries targets + +#LIB = libSALOME_Swigcmodule.la +LIB_SRC = + +#SWIG_DEF = libSALOME_Swig.i +EXPORT_PYSCRIPTS = Help.py PyInterp.py salome.py examplevtk1.py supervisionexample.py supervisiongeomexample.py salome_shared_modules.py batchmode_salome.py test_table.py test_big_table.py test_many_objects.py import_hook.py salome_test.py + +EXPORT_SHAREDPYSCRIPTS=kernel_shared_modules.py + +#LIB_CLIENT_IDL = SALOMEDS.idl \ + #SALOME_Exception.idl + +#CPPFLAGS+=$(QT_INCLUDES) $(PYTHON_INCLUDES) $(OCC_INCLUDES) $(VTK_INCLUDES) $(OGL_INCLUDES) -DHAVE_CONFIG_H +#LIBS+= $(PYTHON_LIBS) +#LDFLAGS+= -lSalomeGUI + +@CONCLUDE@ diff --git a/src/SALOME_SWIG/PyInterp.py b/src/SALOME_SWIG_WITHOUTIHM/PyInterp.py old mode 100644 new mode 100755 similarity index 100% rename from src/SALOME_SWIG/PyInterp.py rename to src/SALOME_SWIG_WITHOUTIHM/PyInterp.py diff --git a/src/SALOME_SWIG_WITHOUTIHM/batchmode_salome.py b/src/SALOME_SWIG_WITHOUTIHM/batchmode_salome.py new file mode 100755 index 000000000..d0c17b264 --- /dev/null +++ b/src/SALOME_SWIG_WITHOUTIHM/batchmode_salome.py @@ -0,0 +1,219 @@ +# Copyright (C) 2003 CEA/DEN, EDF R&D +# +# +# +# File : batchmode_salome.py +# Module : SALOME + +import salome_shared_modules + +from omniORB import CORBA +from LifeCycleCORBA import * +import SALOMEDS +from SALOME_NamingServicePy import * + +#-------------------------------------------------------------------------- + +def ImportComponentGUI(ComponentName): + libName = "lib" + ComponentName + "_Swig" + command = "from " + libName + " import *" + exec ( command ) + constructor = ComponentName + "GUI_Swig()" + command = "gui = " + constructor + exec ( command ) + return gui + + #-------------------------------------------------------------------------- + +def SalomeGUIgetAllSelected(self): + selNumber = self.SelectedCount() + listSelected = [] + for i in range(selNumber): + listSelected.append(self.getSelected(i)) + return listSelected + #-------------------------------------------------------------------------- + +def generateName(prefix = None): + import whrandom; + int = whrandom.randint(1,1000); + if prefix is None: + return "Study" + str(int) + else : + return prefix + str(int) + +#WITHOUTIHMfrom libSALOME_Swig import * +###from SalomePyQt import * +#WITHOUTIHMclass SalomeGUI(SALOMEGUI_Swig): + #WITHOUTIHMgetAllSelected = SalomeGUIgetAllSelected + + #WITHOUTIHMdef getDesktop(self) : +# return SalomePyQt.getDesktop() + #WITHOUTIHMreturn None + + #WITHOUTIHMdef getSelection(self) : +# #WITHOUTIHMreturn SalomePyQt.getSelection() + #WITHOUTIHMreturn None + + #-------------------------------------------------------------------------- + +def IDToObject(id): + mySO = myStudy.FindObjectID(id); + print id + Builder = myStudy.NewBuilder() + anAttr = Builder.FindOrCreateAttribute(mySO, "AttributeIOR") + AtIOR = anAttr._narrow(SALOMEDS.AttributeIOR) + myObj = orb.string_to_object(AtIOR.Value()) + return myObj + +def IDToSObject(id): + mySO = myStudy.FindObjectID(id); + return mySO + + #-------------------------------------------------------------------------- + +def PersistentPresentation(theStudy, theSO, theWithID): + # put the sobject's content (with subchildren) to the string + aResult = "" + attrs = theSO.GetAllAttributes() + aLen = len(attrs) + anUncopied = 0 + for a in range(0,aLen): + attr = attrs[a] + if isinstance(attr,SALOMEDS._objref_AttributeTreeNode): + anUncopied += 1 + elif isinstance(attr,SALOMEDS._objref_AttributeTarget): + anUncopied += 1 + elif isinstance(attr,SALOMEDS._objref_AttributeReal) or \ + isinstance(attr,SALOMEDS._objref_AttributeInteger) or \ + isinstance(attr,SALOMEDS._objref_AttributeName) or \ + isinstance(attr,SALOMEDS._objref_AttributeComment) or \ + isinstance(attr,SALOMEDS._objref_AttributePersistentRef) or \ + isinstance(attr,SALOMEDS._objref_AttributeLocalID) or \ + isinstance(attr,SALOMEDS._objref_AttributeUserID): + aResult += " attribute value: " + str(attr.Value()) + elif isinstance(attr,SALOMEDS._objref_AttributeIOR): + aResult += " attribute: IOR" + elif isinstance(attr,SALOMEDS._objref_AttributeSequenceOfReal) or \ + isinstance(attr,SALOMEDS._objref_AttributeSequenceOfInteger): + aResult += " Sequence: " + str(attr.CorbaSequence()) + elif isinstance(attr,SALOMEDS._objref_AttributeDrawable): + aResult += " Drawable: " + str(attr.IsDrawable()) + elif isinstance(attr,SALOMEDS._objref_AttributeSelectable): + aResult += " Selectable: " + str(attr.IsSelectable()) + elif isinstance(attr,SALOMEDS._objref_AttributeExpandable): + aResult += " Expandable: " + str(attr.IsExpandable()) + elif isinstance(attr,SALOMEDS._objref_AttributeOpened): + aResult += " Opened: " + str(attr.IsOpened()) + elif isinstance(attr,SALOMEDS._objref_AttributeTextColor): + aResult += " TextColor: " + str(attr.TextColor()) + elif isinstance(attr,SALOMEDS._objref_AttributeTextHighlightColor): + aResult += " TextHighlightColor: " + str(attr.TextHighlightColor()) + elif isinstance(attr,SALOMEDS._objref_AttributePixMap): + aResult += " PixMap: " + str(attr.GetPixMap()) + elif isinstance(attr,SALOMEDS._objref_AttributeTableOfInteger) or \ + isinstance(attr,SALOMEDS._objref_AttributeTableOfReal): + aResult += " Table with title: " + attr.GetTitle() + elif isinstance(attr,SALOMEDS._objref_AttributePythonObject): + aResult += " PythonObject: " + attr.GetObject() + + if theWithID: + aResult = "sobject: " + theSO.GetID() + " nbattrs: " + str(aLen - anUncopied) + aResult + '\n' + else: + aResult = " nbattrs: " + str(aLen - anUncopied) + aResult + '\n' + anIter = theStudy.NewChildIterator(theSO) + while anIter.More(): + aResult += PersistentPresentation(theStudy, anIter.Value(), theWithID) + anIter.Next() + return aResult + + #-------------------------------------------------------------------------- + +def GetTree(theSO): + # returns the document list tree (as list) + aResult = [theSO.GetID()] + anIter = myStudy.NewChildIterator(theSO) + while anIter.More(): + aResult += GetTree(anIter.Value()) + anIter.Next() + return aResult + + #-------------------------------------------------------------------------- + +def CheckCopyPaste(theSO, theInfo ,theComponentPaste): + aRoot = theSO + while aRoot.GetID() != "0:": + aRoot = aRoot.GetFather() + aTree = GetTree(aRoot) + aStudyPersist = PersistentPresentation(myStudy, aRoot, 1) + + if not myStudyManager.CanCopy(theSO): + raise RuntimeError, " for "+theInfo+" returns false" + + if not myStudyManager.Copy(theSO): + raise RuntimeError, " for "+theInfo+" returns false" + + + if not myStudyManager.CanPaste(theSO): + raise RuntimeError, " for "+theInfo+" returns false" + + # check: before paste study is not changed check + if aStudyPersist != PersistentPresentation(myStudy, aRoot, 1): + raise RuntimeError, "Study is changed before Paste calling for "+theInfo + + aSObj = theSO + if theComponentPaste: + aSObj = theSO.GetFatherComponent() + theInfo = theInfo + "(paste for component)" + if not myStudyManager.Paste(aSObj): + raise RuntimeError, " for "+theInfo+" returns false" + aNewTree = GetTree(aRoot) + aLen = len(aTree) + for a in range(0,aLen): + if aTree[a] != aNewTree[a]: + return myStudy.FindObjectID(aNewTree[a]) + + if aLen < len(aNewTree): + return myStudy.FindObjectID(aNewTree[aLen]) + + raise RuntimeError, "After Copy calling the tree is not changed" + + #-------------------------------------------------------------------------- +def FindFileInDataDir(filename): + import os + datadir = os.getenv("DATA_DIR") + if datadir is not None: + import string + dirs = string.split(datadir, ":") + for dir in dirs: + file = dir + "/" + filename + if os.path.exists(file): + return file; + datadir = os.getenv("KERNEL_ROOT_DIR") + "/examples/" + file = datadir + filename + if os.path.exists(file): + return file; + + return None + +#-------------------------------------------------------------------------- +# initialise the ORB +orb = CORBA.ORB_init([''], CORBA.ORB_ID) + +# create an LifeCycleCORBA instance +lcc = LifeCycleCORBA(orb) + +#create a naming service instance +naming_service = SALOME_NamingServicePy_i(orb) + +# get Study Manager reference +obj = naming_service.Resolve('myStudyManager') +myStudyManager = obj._narrow(SALOMEDS.StudyManager) + +# create new study +myStudy = myStudyManager.NewStudy("Study1") + +myStudyName = myStudy._get_Name() + +myStudyId = myStudy._get_StudyId() +print myStudyId + diff --git a/src/SALOME_SWIG/examplevtk1.py b/src/SALOME_SWIG_WITHOUTIHM/examplevtk1.py old mode 100644 new mode 100755 similarity index 100% rename from src/SALOME_SWIG/examplevtk1.py rename to src/SALOME_SWIG_WITHOUTIHM/examplevtk1.py diff --git a/src/SALOME_SWIG/import_hook.py b/src/SALOME_SWIG_WITHOUTIHM/import_hook.py old mode 100644 new mode 100755 similarity index 100% rename from src/SALOME_SWIG/import_hook.py rename to src/SALOME_SWIG_WITHOUTIHM/import_hook.py diff --git a/src/SALOME_SWIG/kernel_shared_modules.py b/src/SALOME_SWIG_WITHOUTIHM/kernel_shared_modules.py old mode 100644 new mode 100755 similarity index 96% rename from src/SALOME_SWIG/kernel_shared_modules.py rename to src/SALOME_SWIG_WITHOUTIHM/kernel_shared_modules.py index 1ba9d8bf3..f1ed96442 --- a/src/SALOME_SWIG/kernel_shared_modules.py +++ b/src/SALOME_SWIG_WITHOUTIHM/kernel_shared_modules.py @@ -17,6 +17,8 @@ register_name("Engines") register_name("SALOME") register_name("SALOMEDS") register_name("SALOME_ModuleCatalog") +register_name("Resources") +register_name("Containers") # BE CAREFUL # Engines, SALOME, SALOMEDS must be imported in that order because : @@ -29,6 +31,8 @@ import SALOME import SALOMEDS import SALOME_ModuleCatalog +import Resources +import Containers from SALOME_utilities import MESSAGE # # We search all Python CORBA (omniorb) modules. diff --git a/src/SALOME_SWIG/salome.py b/src/SALOME_SWIG_WITHOUTIHM/salome.py old mode 100644 new mode 100755 similarity index 100% rename from src/SALOME_SWIG/salome.py rename to src/SALOME_SWIG_WITHOUTIHM/salome.py diff --git a/src/SALOME_SWIG/salome_shared_modules.py b/src/SALOME_SWIG_WITHOUTIHM/salome_shared_modules.py old mode 100644 new mode 100755 similarity index 100% rename from src/SALOME_SWIG/salome_shared_modules.py rename to src/SALOME_SWIG_WITHOUTIHM/salome_shared_modules.py diff --git a/src/SALOME_SWIG/salome_test.py b/src/SALOME_SWIG_WITHOUTIHM/salome_test.py old mode 100644 new mode 100755 similarity index 100% rename from src/SALOME_SWIG/salome_test.py rename to src/SALOME_SWIG_WITHOUTIHM/salome_test.py diff --git a/src/SALOME_SWIG_WITHOUTIHM/supervisionexample.py.in b/src/SALOME_SWIG_WITHOUTIHM/supervisionexample.py.in new file mode 100755 index 000000000..56bdd9bf5 --- /dev/null +++ b/src/SALOME_SWIG_WITHOUTIHM/supervisionexample.py.in @@ -0,0 +1,85 @@ +#============================================================================== +# File : supervisionexample.py +# Created : 23 nov 2001 +# Author : Jean Rahuel +# Project : SALOME +# Copyright : CEA +#============================================================================== + +from SuperV import * + + + +# load this object with Nodes, Links and Datas stored in GraphEssai.xml +# (GraphEssai.xml was created with python in SuperVisionTest and GraphEssai.py) +myGraph = Graph("@ROOT_BUILDDIR@/share/salome/resources/GraphEssai.xml") + +#myGraph = Graph("/home/data/jr_HEAD/build/share/salome/resources/GraphEssai.xml") +# This DataFlow is "valid" : no loop, correct links between Nodes etc... + +print myGraph.IsValid() + +# Get Nodes +myGraph.PrintNodes() +Add,Sub,Mul,Div = myGraph.Nodes() + +# Load Datas +Addx = Add.Input("x",3.) +Addy = Add.Input("y",4.5) +Subx = Sub.Input("x",1.5) + +# Get Output Port +Addz = Add.Port('z') +Subz = Sub.Port('z') +Mulz = Mul.Port('z') +Divz = Div.Port('z') + +# This DataFlow is "executable" : all pending Ports are defined with Datas +print myGraph.IsExecutable() + +# Starts only execution of that DataFlow and gets control immediatly +print myGraph.Run() + +# That DataFlow is running ==> 0 (false) +print myGraph.IsDone() + +# Events of execution : +aStatus,aNode,anEvent,aState = myGraph.Event() +while aStatus : + print aNode.Thread(),aNode.SubGraph(),aNode.Name(),anEvent,aState + aStatus,aNode,anEvent,aState = myGraph.Event() +print myGraph.IsDone() + +# Wait for Completion (but it is already done after event loop ...) +print "Done : ",myGraph.DoneW() + +# Get result +print "Result : ",Divz.ToString() + +# Intermediate results : +print "Intermediate Result Add\z : ",Addz.ToString() +print "Intermediate Result Sub\z : ",Subz.ToString() +print "Intermediate Result Mul\z : ",Mulz.ToString() + +print " " +print "Type : print myGraph.IsDone()" +print " If execution is finished ==> 1 (true)" +print " " +print "Type : print Divz.ToString()" +print " You will get the result" +print " " +print "Type : myGraph.PrintPorts()" +print " to see input and output values of the graph" +print " " +print "Type : Add.PrintPorts()" +print "Type : Sub.PrintPorts()" +print "Type : Mul.PrintPorts()" +print "Type : Div.PrintPorts()" +print " to see input and output values of nodes" + +# Export will create newsupervisionexample.xml and the corresponding .py file +print myGraph.Export("@ROOT_BUILDDIR@/share/salome/resources/newsupervisionexample.xml") + +print " " +print "See file @ROOT_BUILDDIR@/share/salome/resources/newsupervisionexample.xml" +print "See file @ROOT_BUILDDIR@/share/salome/resources/newsupervisionexample.py" diff --git a/src/SALOME_SWIG_WITHOUTIHM/supervisiongeomexample.py.in b/src/SALOME_SWIG_WITHOUTIHM/supervisiongeomexample.py.in new file mode 100755 index 000000000..8c56bb1f2 --- /dev/null +++ b/src/SALOME_SWIG_WITHOUTIHM/supervisiongeomexample.py.in @@ -0,0 +1,103 @@ + +# Generated python file of Graph GraphGeom2Essai + +from SuperV import * + +import salome + +import geompy + + +geom = lcc.FindOrLoadComponent("FactoryServer", "Geometry") +geom.GetCurrentStudy(salome.myStudyId) + +myBuilder = salome.myStudy.NewBuilder() + +# Graph creation +GraphGeom2Essai = Graph( 'GraphGeom2Essai' ) +print GraphGeom2Essai.SetAuthor( '' ) +print GraphGeom2Essai.SetComment( '' ) +GraphGeom2Essai.Coords( 0 , 0 ) + +# Creation of Nodes +MakeSphere = GraphGeom2Essai.Node( 'Geometry' , 'Geometry' , 'MakeSphere' ) +print MakeSphere.SetAuthor( '' ) +print MakeSphere.SetContainer( 'FactoryServer' ) +print MakeSphere.SetComment( '' ) +MakeSphere.Coords( 26 , 13 ) +MakeCopy = GraphGeom2Essai.Node( 'Geometry' , 'Geometry' , 'MakeCopy' ) +print MakeCopy.SetAuthor( '' ) +print MakeCopy.SetContainer( 'FactoryServer' ) +print MakeCopy.SetComment( '' ) +MakeCopy.Coords( 219 , 12 ) +MakeTranslation = GraphGeom2Essai.Node( 'Geometry' , 'Geometry' , 'MakeTranslation' ) +print MakeTranslation.SetAuthor( '' ) +print MakeTranslation.SetContainer( 'FactoryServer' ) +print MakeTranslation.SetComment( '' ) +MakeTranslation.Coords( 219 , 159 ) +MakeFuse = GraphGeom2Essai.Node( 'Geometry' , 'Geometry' , 'MakeFuse' ) +print MakeFuse.SetAuthor( '' ) +print MakeFuse.SetContainer( 'FactoryServer' ) +print MakeFuse.SetComment( '' ) +MakeFuse.Coords( 465 , 106 ) + +# Creation of intermediate Output variables and of links +MakeSphereshape = MakeSphere.Port( 'shape' ) +MakeCopyshape1 = GraphGeom2Essai.Link( MakeSphereshape , MakeCopy.Port( 'shape1' ) ) +MakeTranslationshape1 = GraphGeom2Essai.Link( MakeSphereshape , MakeTranslation.Port( 'shape1' ) ) +MakeCopyshape = MakeCopy.Port( 'shape' ) +MakeFuseshape1 = GraphGeom2Essai.Link( MakeCopyshape , MakeFuse.Port( 'shape1' ) ) +MakeTranslationshape = MakeTranslation.Port( 'shape' ) +MakeFuseshape2 = GraphGeom2Essai.Link( MakeTranslationshape , MakeFuse.Port( 'shape2' ) ) + +# Creation of Input datas +MakeSpherex1 = MakeSphere.Input( 'x1' , 0) +MakeSpherey1 = MakeSphere.Input( 'y1' , 0) +MakeSpherez1 = MakeSphere.Input( 'z1' , 0) +MakeSphereradius = MakeSphere.Input( 'radius' , 50) +MakeTranslationx1 = MakeTranslation.Input( 'x1' , 80) +MakeTranslationy1 = MakeTranslation.Input( 'y1' , 0) +MakeTranslationz1 = MakeTranslation.Input( 'z1' , 0) + +# Missing Input datas : None + +# Creation of Output variables +MakeFuseshape = MakeFuse.Port( 'shape' ) + +# State of Ports of the Graph +GraphGeom2Essai.PrintPorts() + +# Start asynchronous run +print GraphGeom2Essai.Run() + +# Done ? +print GraphGeom2Essai.IsDone() + +# Events of execution : +aStatus,aNode,anEvent,aState = GraphGeom2Essai.Event() +while aStatus : + print aNode.Thread(),aNode.SubGraph(),aNode.Name(),anEvent,aState + aStatus,aNode,anEvent,aState = GraphGeom2Essai.Event() +print GraphGeom2Essai.IsDone() + +# Waiting end of execution : +print GraphGeom2Essai.DoneW() + +print " " +print "Type print GraphGeom2Essai.IsDone()" +print "1 <==> It's done" +print " " +print "Type print GraphGeom2Essai.DoneW()" +print "Wait until end of execution : 1(success)" +print " " +print "Type GraphGeom2Essai.PrintPorts()" +print " to see input and output values of the graph" +print " " +print "Type MakeSphere.PrintPorts()" +print "Type MakeCopy.PrintPorts()" +print "Type MakeTranslation.PrintPorts()" +print "Type MakeFuse.PrintPorts()" +print " to see input and output values of nodes" +print " " +print "Type print GraphGeom2Essai.Export('File-Name')" +print "You will get a .py and a .xml file of this graph" diff --git a/src/SALOME_SWIG/test_big_table.py b/src/SALOME_SWIG_WITHOUTIHM/test_big_table.py old mode 100644 new mode 100755 similarity index 100% rename from src/SALOME_SWIG/test_big_table.py rename to src/SALOME_SWIG_WITHOUTIHM/test_big_table.py diff --git a/src/SALOME_SWIG/test_many_objects.py b/src/SALOME_SWIG_WITHOUTIHM/test_many_objects.py old mode 100644 new mode 100755 similarity index 100% rename from src/SALOME_SWIG/test_many_objects.py rename to src/SALOME_SWIG_WITHOUTIHM/test_many_objects.py diff --git a/src/SALOME_SWIG/test_table.py b/src/SALOME_SWIG_WITHOUTIHM/test_table.py old mode 100644 new mode 100755 similarity index 100% rename from src/SALOME_SWIG/test_table.py rename to src/SALOME_SWIG_WITHOUTIHM/test_table.py diff --git a/src/SALOME_SWIG/testattr.py b/src/SALOME_SWIG_WITHOUTIHM/testattr.py old mode 100644 new mode 100755 similarity index 100% rename from src/SALOME_SWIG/testattr.py rename to src/SALOME_SWIG_WITHOUTIHM/testattr.py -- 2.39.2