--- /dev/null
+
+# Generated python file of Graph GraphSwitchCheck
+
+from SuperV import *
+
+# Graph creation of GraphSwitchCheck
+def DefGraphSwitchCheck() :
+ GraphSwitchCheck = Graph( 'GraphSwitchCheck' )
+ GraphSwitchCheck.SetName( 'GraphSwitchCheck' )
+ GraphSwitchCheck.SetAuthor( 'JR' )
+ GraphSwitchCheck.SetComment( '' )
+ GraphSwitchCheck.Coords( 0 , 0 )
+
+ # Creation of Factory Nodes
+
+ # Creation of InLine Nodes
+ PyIsOdd = []
+ PyIsOdd.append( 'from time import * ' )
+ PyIsOdd.append( 'def IsOdd(a) : ' )
+ PyIsOdd.append( ' print a,"IsOdd (GraphSwitch)" ' )
+ PyIsOdd.append( ' sleep( 1 ) ' )
+ PyIsOdd.append( ' return a ' )
+ IsOdd = GraphSwitchCheck.INode( 'IsOdd' , PyIsOdd )
+ IsOdd.SetName( 'IsOdd' )
+ IsOdd.SetAuthor( '' )
+ IsOdd.SetComment( 'Python function' )
+ IsOdd.Coords( 415 , 7 )
+ IIsOdda = IsOdd.InPort( 'a' , 'long' )
+ IIsOddGate = IsOdd.GetInPort( 'Gate' )
+ OIsOdda = IsOdd.OutPort( 'a' , 'long' )
+ OIsOddGate = IsOdd.GetOutPort( 'Gate' )
+
+ PyIsEven = []
+ PyIsEven.append( 'from time import * ' )
+ PyIsEven.append( 'def IsEven(a) : ' )
+ PyIsEven.append( ' print a,"IsEven (GraphSwitch)" ' )
+ PyIsEven.append( ' sleep( 1 ) ' )
+ PyIsEven.append( ' return a ' )
+ IsEven = GraphSwitchCheck.INode( 'IsEven' , PyIsEven )
+ IsEven.SetName( 'IsEven' )
+ IsEven.SetAuthor( '' )
+ IsEven.SetComment( 'Compute Node' )
+ IsEven.Coords( 421 , 438 )
+ IIsEvena = IsEven.InPort( 'a' , 'long' )
+ IIsEvenGate = IsEven.GetInPort( 'Gate' )
+ OIsEvena = IsEven.OutPort( 'a' , 'long' )
+ OIsEvenGate = IsEven.GetOutPort( 'Gate' )
+
+ PyPrintOdd = []
+ PyPrintOdd.append( 'from time import * ' )
+ PyPrintOdd.append( 'def Print(a,Branch) : ' )
+ PyPrintOdd.append( ' print "Print ",a,Branch ' )
+ PyPrintOdd.append( ' sleep(1) ' )
+ PyPrintOdd.append( ' return Branch ' )
+ PrintOdd = GraphSwitchCheck.INode( 'Print' , PyPrintOdd )
+ PrintOdd.SetName( 'PrintOdd' )
+ PrintOdd.SetAuthor( '' )
+ PrintOdd.SetComment( 'Compute Node' )
+ PrintOdd.Coords( 415 , 130 )
+ IPrintOdda = PrintOdd.InPort( 'a' , 'long' )
+ IPrintOddBranch = PrintOdd.InPort( 'Branch' , 'string' )
+ IPrintOddGate = PrintOdd.GetInPort( 'Gate' )
+ OPrintOddBranch = PrintOdd.OutPort( 'Branch' , 'string' )
+ OPrintOddGate = PrintOdd.GetOutPort( 'Gate' )
+
+ PyPrintEven = []
+ PyPrintEven.append( 'from time import * ' )
+ PyPrintEven.append( 'def Print_1(a,Branch) : ' )
+ PyPrintEven.append( ' print "Print ",a,Branch ' )
+ PyPrintEven.append( ' sleep(1) ' )
+ PyPrintEven.append( ' return Branch ' )
+ PrintEven = GraphSwitchCheck.INode( 'Print_1' , PyPrintEven )
+ PrintEven.SetName( 'PrintEven' )
+ PrintEven.SetAuthor( '' )
+ PrintEven.SetComment( 'Compute Node' )
+ PrintEven.Coords( 423 , 289 )
+ IPrintEvena = PrintEven.InPort( 'a' , 'long' )
+ IPrintEvenBranch = PrintEven.InPort( 'Branch' , 'string' )
+ IPrintEvenGate = PrintEven.GetInPort( 'Gate' )
+ OPrintEvenBranch = PrintEven.OutPort( 'Branch' , 'string' )
+ OPrintEvenGate = PrintEven.GetOutPort( 'Gate' )
+
+ PyEmptyNode = []
+ PyEmptyNode.append( 'from time import * ' )
+ PyEmptyNode.append( 'def EmptyNode(a,Branch) : ' )
+ PyEmptyNode.append( ' sleep(1) ' )
+ PyEmptyNode.append( ' return a,Branch ' )
+ EmptyNode = GraphSwitchCheck.INode( 'EmptyNode' , PyEmptyNode )
+ EmptyNode.SetName( 'EmptyNode' )
+ EmptyNode.SetAuthor( '' )
+ EmptyNode.SetComment( 'Compute Node' )
+ EmptyNode.Coords( 652 , 110 )
+ IEmptyNodea = EmptyNode.InPort( 'a' , 'long' )
+ IEmptyNodeBranch = EmptyNode.InPort( 'Branch' , 'string' )
+ IEmptyNodeGate = EmptyNode.GetInPort( 'Gate' )
+ OEmptyNodea = EmptyNode.OutPort( 'a' , 'long' )
+ OEmptyNodeBranch = EmptyNode.OutPort( 'Branch' , 'string' )
+ OEmptyNodeGate = EmptyNode.GetOutPort( 'Gate' )
+
+ # Creation of Loop Nodes
+ PyInitLoopSwitch = []
+ PyInitLoopSwitch.append( 'def InitLoop(Index,Min,Max) : ' )
+ PyInitLoopSwitch.append( ' Index = Max ' )
+ PyInitLoopSwitch.append( ' return Index,Min,Max ' )
+ PyMoreInitLoopSwitch = []
+ PyMoreInitLoopSwitch.append( 'from time import * ' )
+ PyMoreInitLoopSwitch.append( 'def MoreLoop(Index,Min,Max) : ' )
+ PyMoreInitLoopSwitch.append( ' sleep(1) ' )
+ PyMoreInitLoopSwitch.append( ' if Index >= Min : ' )
+ PyMoreInitLoopSwitch.append( ' DoLoop = 1 ' )
+ PyMoreInitLoopSwitch.append( ' else : ' )
+ PyMoreInitLoopSwitch.append( ' DoLoop = 0 ' )
+ PyMoreInitLoopSwitch.append( ' return DoLoop,Index,Min,Max ' )
+ PyNextInitLoopSwitch = []
+ PyNextInitLoopSwitch.append( 'def NextLoop(Index,Min,Max) : ' )
+ PyNextInitLoopSwitch.append( ' Index = Index - 1 ' )
+ PyNextInitLoopSwitch.append( ' return Index,Min,Max ' )
+ InitLoopSwitch,EndOfInitLoopSwitch = GraphSwitchCheck.LNode( 'InitLoop' , PyInitLoopSwitch , 'MoreLoop' , PyMoreInitLoopSwitch , 'NextLoop' , PyNextInitLoopSwitch )
+ EndOfInitLoopSwitch.SetName( 'EndOfInitLoopSwitch' )
+ EndOfInitLoopSwitch.SetAuthor( '' )
+ EndOfInitLoopSwitch.SetComment( 'Compute Node' )
+ EndOfInitLoopSwitch.Coords( 1074 , 194 )
+ PyEndOfInitLoopSwitch = []
+ PyEndOfInitLoopSwitch.append( 'from time import * ' )
+ PyEndOfInitLoopSwitch.append( 'def EndOfInitLoopSwitch(DoLoop,Index,Min,Max) : ' )
+ PyEndOfInitLoopSwitch.append( ' sleep(1) ' )
+ PyEndOfInitLoopSwitch.append( ' return DoLoop,Index,Min,Max ' )
+ EndOfInitLoopSwitch.SetPyFunction( 'EndOfInitLoopSwitch' , PyEndOfInitLoopSwitch )
+ IInitLoopSwitchDoLoop = InitLoopSwitch.GetInPort( 'DoLoop' )
+ IInitLoopSwitchIndex = InitLoopSwitch.InPort( 'Index' , 'long' )
+ IInitLoopSwitchMin = InitLoopSwitch.InPort( 'Min' , 'long' )
+ IInitLoopSwitchMax = InitLoopSwitch.InPort( 'Max' , 'long' )
+ IInitLoopSwitchGate = InitLoopSwitch.GetInPort( 'Gate' )
+ OInitLoopSwitchDoLoop = InitLoopSwitch.GetOutPort( 'DoLoop' )
+ OInitLoopSwitchIndex = InitLoopSwitch.GetOutPort( 'Index' )
+ OInitLoopSwitchMin = InitLoopSwitch.GetOutPort( 'Min' )
+ OInitLoopSwitchMax = InitLoopSwitch.GetOutPort( 'Max' )
+ IEndOfInitLoopSwitchDoLoop = EndOfInitLoopSwitch.GetInPort( 'DoLoop' )
+ IEndOfInitLoopSwitchIndex = EndOfInitLoopSwitch.GetInPort( 'Index' )
+ IEndOfInitLoopSwitchMin = EndOfInitLoopSwitch.GetInPort( 'Min' )
+ IEndOfInitLoopSwitchMax = EndOfInitLoopSwitch.GetInPort( 'Max' )
+ IEndOfInitLoopSwitchGate = EndOfInitLoopSwitch.GetInPort( 'Gate' )
+ OEndOfInitLoopSwitchDoLoop = EndOfInitLoopSwitch.GetOutPort( 'DoLoop' )
+ OEndOfInitLoopSwitchIndex = EndOfInitLoopSwitch.GetOutPort( 'Index' )
+ OEndOfInitLoopSwitchMin = EndOfInitLoopSwitch.GetOutPort( 'Min' )
+ OEndOfInitLoopSwitchMax = EndOfInitLoopSwitch.GetOutPort( 'Max' )
+ OEndOfInitLoopSwitchGate = EndOfInitLoopSwitch.GetOutPort( 'Gate' )
+ InitLoopSwitch.SetName( 'InitLoopSwitch' )
+ InitLoopSwitch.SetAuthor( '' )
+ InitLoopSwitch.SetComment( 'Compute Node' )
+ InitLoopSwitch.Coords( 10 , 129 )
+
+ # Creation of Switch Nodes
+ PySwitch = []
+ PySwitch.append( 'from time import * ' )
+ PySwitch.append( 'def Switch(a) : ' )
+ PySwitch.append( ' sleep(1) ' )
+ PySwitch.append( ' Branch = "Negative or null" ' )
+ PySwitch.append( ' if a <= 0 : ' )
+ PySwitch.append( ' return 0,0,a,Branch,1 ' )
+ PySwitch.append( ' if ( a & 1 ) == 0 : ' )
+ PySwitch.append( ' Branch = "Even" ' )
+ PySwitch.append( ' else : ' )
+ PySwitch.append( ' Branch = "Odd" ' )
+ PySwitch.append( ' return a & 1,1-(a&1),a,Branch,0 ' )
+ Switch,EndOfSwitch = GraphSwitchCheck.SNode( 'Switch' , PySwitch )
+ EndOfSwitch.SetName( 'EndOfSwitch' )
+ EndOfSwitch.SetAuthor( '' )
+ EndOfSwitch.SetComment( 'Compute Node' )
+ EndOfSwitch.Coords( 882 , 194 )
+ PyEndOfSwitch = []
+ PyEndOfSwitch.append( 'from time import * ' )
+ PyEndOfSwitch.append( 'def EndOfSwitch(a,Branch) : ' )
+ PyEndOfSwitch.append( ' sleep(1) ' )
+ PyEndOfSwitch.append( ' return a ' )
+ EndOfSwitch.SetPyFunction( 'EndOfSwitch' , PyEndOfSwitch )
+ IEndOfSwitcha = EndOfSwitch.InPort( 'a' , 'long' )
+ IEndOfSwitchBranch = EndOfSwitch.InPort( 'Branch' , 'string' )
+ IEndOfSwitchDefault = EndOfSwitch.GetInPort( 'Default' )
+ OEndOfSwitcha = EndOfSwitch.OutPort( 'a' , 'long' )
+ OEndOfSwitchGate = EndOfSwitch.GetOutPort( 'Gate' )
+ Switch.SetName( 'Switch' )
+ Switch.SetAuthor( '' )
+ Switch.SetComment( 'Compute Node' )
+ Switch.Coords( 195 , 129 )
+ ISwitcha = Switch.InPort( 'a' , 'long' )
+ ISwitchGate = Switch.GetInPort( 'Gate' )
+ OSwitchOdd = Switch.OutPort( 'Odd' , 'long' )
+ OSwitchEven = Switch.OutPort( 'Even' , 'int' )
+ OSwitcha = Switch.OutPort( 'a' , 'int' )
+ OSwitchBranch = Switch.OutPort( 'Branch' , 'string' )
+ OSwitchdefault = Switch.OutPort( 'default' , 'boolean' )
+ OSwitchDefault = Switch.GetOutPort( 'Default' )
+
+ # Creation of Links
+ LIsOddaEmptyNodea = GraphSwitchCheck.Link( OIsOdda , IEmptyNodea )
+ LIsOddaEmptyNodea.AddCoord( 1 , 646 , 78 )
+
+ LIsEvenaEndOfSwitcha = GraphSwitchCheck.Link( OIsEvena , IEndOfSwitcha )
+
+ LPrintOddBranchEmptyNodeBranch = GraphSwitchCheck.Link( OPrintOddBranch , IEmptyNodeBranch )
+
+ LPrintEvenBranchEndOfSwitchBranch = GraphSwitchCheck.Link( OPrintEvenBranch , IEndOfSwitchBranch )
+
+ LEmptyNodeaEndOfSwitcha = GraphSwitchCheck.Link( OEmptyNodea , IEndOfSwitcha )
+
+ LEmptyNodeBranchEndOfSwitchBranch = GraphSwitchCheck.Link( OEmptyNodeBranch , IEndOfSwitchBranch )
+
+ LInitLoopSwitchIndexSwitcha = GraphSwitchCheck.Link( OInitLoopSwitchIndex , ISwitcha )
+
+ LInitLoopSwitchMinEndOfInitLoopSwitchMin = GraphSwitchCheck.Link( OInitLoopSwitchMin , IEndOfInitLoopSwitchMin )
+
+ LInitLoopSwitchMaxEndOfInitLoopSwitchMax = GraphSwitchCheck.Link( OInitLoopSwitchMax , IEndOfInitLoopSwitchMax )
+
+ LSwitchOddIsOddGate = GraphSwitchCheck.Link( OSwitchOdd , IIsOddGate )
+ LSwitchOddIsOddGate.AddCoord( 1 , 401 , 101 )
+ LSwitchOddIsOddGate.AddCoord( 2 , 401 , 160 )
+
+ LSwitchOddPrintOddGate = GraphSwitchCheck.Link( OSwitchOdd , IPrintOddGate )
+ LSwitchOddPrintOddGate.AddCoord( 1 , 401 , 245 )
+ LSwitchOddPrintOddGate.AddCoord( 2 , 401 , 159 )
+
+ LSwitchEvenIsEvenGate = GraphSwitchCheck.Link( OSwitchEven , IIsEvenGate )
+ LSwitchEvenIsEvenGate.AddCoord( 1 , 392 , 533 )
+ LSwitchEvenIsEvenGate.AddCoord( 2 , 392 , 182 )
+
+ LSwitchEvenPrintEvenGate = GraphSwitchCheck.Link( OSwitchEven , IPrintEvenGate )
+ LSwitchEvenPrintEvenGate.AddCoord( 1 , 392 , 403 )
+ LSwitchEvenPrintEvenGate.AddCoord( 2 , 392 , 181 )
+
+ LSwitchaIsOdda = GraphSwitchCheck.Link( OSwitcha , IIsOdda )
+ LSwitchaIsOdda.AddCoord( 1 , 382 , 78 )
+ LSwitchaIsOdda.AddCoord( 2 , 382 , 199 )
+
+ LSwitchaIsEvena = GraphSwitchCheck.Link( OSwitcha , IIsEvena )
+ LSwitchaIsEvena.AddCoord( 1 , 381 , 509 )
+ LSwitchaIsEvena.AddCoord( 2 , 382 , 200 )
+
+ LSwitchaPrintOdda = GraphSwitchCheck.Link( OSwitcha , IPrintOdda )
+
+ LSwitchaPrintEvena = GraphSwitchCheck.Link( OSwitcha , IPrintEvena )
+ LSwitchaPrintEvena.AddCoord( 1 , 381 , 361 )
+ LSwitchaPrintEvena.AddCoord( 2 , 382 , 200 )
+
+ LSwitchBranchPrintOddBranch = GraphSwitchCheck.Link( OSwitchBranch , IPrintOddBranch )
+
+ LSwitchBranchPrintEvenBranch = GraphSwitchCheck.Link( OSwitchBranch , IPrintEvenBranch )
+ LSwitchBranchPrintEvenBranch.AddCoord( 1 , 369 , 381 )
+ LSwitchBranchPrintEvenBranch.AddCoord( 2 , 369 , 219 )
+
+ LSwitchDefaultEndOfSwitchDefault = GraphSwitchCheck.Link( OSwitchDefault , IEndOfSwitchDefault )
+
+ LEndOfSwitchaEndOfInitLoopSwitchIndex = GraphSwitchCheck.Link( OEndOfSwitcha , IEndOfInitLoopSwitchIndex )
+
+ # Input datas
+ IInitLoopSwitchIndex.Input( 0 )
+ IInitLoopSwitchMin.Input( -5 )
+ IInitLoopSwitchMax.Input( 10 )
+
+ # Output Ports of the graph
+ #OEndOfInitLoopSwitchIndex = EndOfInitLoopSwitch.GetOutPort( 'Index' )
+ #OEndOfInitLoopSwitchMin = EndOfInitLoopSwitch.GetOutPort( 'Min' )
+ #OEndOfInitLoopSwitchMax = EndOfInitLoopSwitch.GetOutPort( 'Max' )
+ #OSwitchdefault = Switch.GetOutPort( 'default' )
+ return GraphSwitchCheck
+
+
+GraphSwitchCheck = DefGraphSwitchCheck()
--- /dev/null
+<!DOCTYPE SuperGraph>
+<supergraph>
+<dataflow>
+<info-list>
+<node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>GraphSwitchCheck</node-name>
+ <kind>1</kind>
+ <coupled-node>?</coupled-node>
+ <service>
+<service-name>GraphSwitchCheck</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>InitLoopSwitch__Index</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>InitLoopSwitch__Min</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>InitLoopSwitch__Max</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>EndOfInitLoopSwitch__Index</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>EndOfInitLoopSwitch__Min</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>EndOfInitLoopSwitch__Max</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>boolean</outParameter-type>
+ <outParameter-name>Switch__default</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list/>
+ <creation-date>13/1/2005 - 11:48:50</creation-date>
+ <lastmodification-date>13/1/2005 - 11:51:24</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>JR</author>
+ <container>?</container>
+ <comment>?</comment>
+ <x-position>0</x-position>
+ <y-position>0</y-position> </node> </info-list>
+ <node-list>
+<node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>IsOdd</node-name>
+ <kind>3</kind>
+ <coupled-node>?</coupled-node>
+ <service>
+<service-name>IsOdd</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>a</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>a</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>IsOdd</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def IsOdd(a) : ]]></PyFunc>
+ <PyFunc><![CDATA[ print a,"IsOdd (GraphSwitch)" ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep( 1 ) ]]></PyFunc>
+ <PyFunc><![CDATA[ return a ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 11:50:18</creation-date>
+ <lastmodification-date>13/1/2005 - 11:50:18</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Python function</comment>
+ <x-position>415</x-position>
+ <y-position>7</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>IsEven</node-name>
+ <kind>3</kind>
+ <coupled-node>?</coupled-node>
+ <service>
+<service-name>IsEven</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>a</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>a</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>IsEven</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def IsEven(a) : ]]></PyFunc>
+ <PyFunc><![CDATA[ print a,"IsEven (GraphSwitch)" ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep( 1 ) ]]></PyFunc>
+ <PyFunc><![CDATA[ return a ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 11:50:18</creation-date>
+ <lastmodification-date>13/1/2005 - 11:50:18</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>421</x-position>
+ <y-position>438</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>PrintOdd</node-name>
+ <kind>3</kind>
+ <coupled-node>?</coupled-node>
+ <service>
+<service-name>Print</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>a</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>string</inParameter-type>
+ <inParameter-name>Branch</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>string</outParameter-type>
+ <outParameter-name>Branch</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>Print</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def Print(a,Branch) : ]]></PyFunc>
+ <PyFunc><![CDATA[ print "Print ",a,Branch ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep(1) ]]></PyFunc>
+ <PyFunc><![CDATA[ return Branch ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 11:50:18</creation-date>
+ <lastmodification-date>13/1/2005 - 11:50:18</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>415</x-position>
+ <y-position>130</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>PrintEven</node-name>
+ <kind>3</kind>
+ <coupled-node>?</coupled-node>
+ <service>
+<service-name>Print_1</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>a</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>string</inParameter-type>
+ <inParameter-name>Branch</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>string</outParameter-type>
+ <outParameter-name>Branch</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>Print_1</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def Print_1(a,Branch) : ]]></PyFunc>
+ <PyFunc><![CDATA[ print "Print ",a,Branch ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep(1) ]]></PyFunc>
+ <PyFunc><![CDATA[ return Branch ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 11:50:18</creation-date>
+ <lastmodification-date>13/1/2005 - 11:50:18</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>423</x-position>
+ <y-position>289</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>EmptyNode</node-name>
+ <kind>3</kind>
+ <coupled-node>?</coupled-node>
+ <service>
+<service-name>EmptyNode</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>a</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>string</inParameter-type>
+ <inParameter-name>Branch</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>a</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>string</outParameter-type>
+ <outParameter-name>Branch</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>EmptyNode</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def EmptyNode(a,Branch) : ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep(1) ]]></PyFunc>
+ <PyFunc><![CDATA[ return a,Branch ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 11:50:18</creation-date>
+ <lastmodification-date>13/1/2005 - 11:50:18</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>652</x-position>
+ <y-position>110</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>InitLoopSwitch</node-name>
+ <kind>4</kind>
+ <coupled-node>EndOfInitLoopSwitch</coupled-node>
+ <service>
+<service-name>InitLoopSwitch</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>Index</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>Min</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>Max</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>Index</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>Min</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>Max</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>InitLoop</FuncName>
+ <PyFunc><![CDATA[def InitLoop(Index,Min,Max) : ]]></PyFunc>
+ <PyFunc><![CDATA[ Index = Max ]]></PyFunc>
+ <PyFunc><![CDATA[ return Index,Min,Max ]]></PyFunc> </PyFunction>
+ <PyFunction>
+<FuncName>MoreLoop</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def MoreLoop(Index,Min,Max) : ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep(1) ]]></PyFunc>
+ <PyFunc><![CDATA[ if Index >= Min : ]]></PyFunc>
+ <PyFunc><![CDATA[ DoLoop = 1 ]]></PyFunc>
+ <PyFunc><![CDATA[ else : ]]></PyFunc>
+ <PyFunc><![CDATA[ DoLoop = 0 ]]></PyFunc>
+ <PyFunc><![CDATA[ return DoLoop,Index,Min,Max ]]></PyFunc> </PyFunction>
+ <PyFunction>
+<FuncName>NextLoop</FuncName>
+ <PyFunc><![CDATA[def NextLoop(Index,Min,Max) : ]]></PyFunc>
+ <PyFunc><![CDATA[ Index = Index - 1 ]]></PyFunc>
+ <PyFunc><![CDATA[ return Index,Min,Max ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 11:50:18</creation-date>
+ <lastmodification-date>13/1/2005 - 11:50:18</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>10</x-position>
+ <y-position>129</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>EndOfInitLoopSwitch</node-name>
+ <kind>5</kind>
+ <coupled-node>InitLoopSwitch</coupled-node>
+ <service>
+<service-name>EndOfInitLoopSwitch</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>Index</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>Min</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>Max</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>Index</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>Min</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>Max</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>EndOfInitLoopSwitch</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def EndOfInitLoopSwitch(DoLoop,Index,Min,Max) : ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep(1) ]]></PyFunc>
+ <PyFunc><![CDATA[ return DoLoop,Index,Min,Max ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 11:50:18</creation-date>
+ <lastmodification-date>13/1/2005 - 11:50:18</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>1074</x-position>
+ <y-position>194</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>Switch</node-name>
+ <kind>6</kind>
+ <coupled-node>EndOfSwitch</coupled-node>
+ <service>
+<service-name>Switch</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>a</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>Odd</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>int</outParameter-type>
+ <outParameter-name>Even</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>int</outParameter-type>
+ <outParameter-name>a</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>string</outParameter-type>
+ <outParameter-name>Branch</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>boolean</outParameter-type>
+ <outParameter-name>default</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>Switch</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def Switch(a) : ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep(1) ]]></PyFunc>
+ <PyFunc><![CDATA[ Branch = "Negative or null" ]]></PyFunc>
+ <PyFunc><![CDATA[ if a <= 0 : ]]></PyFunc>
+ <PyFunc><![CDATA[ return 0,0,a,Branch,1 ]]></PyFunc>
+ <PyFunc><![CDATA[ if ( a & 1 ) == 0 : ]]></PyFunc>
+ <PyFunc><![CDATA[ Branch = "Even" ]]></PyFunc>
+ <PyFunc><![CDATA[ else : ]]></PyFunc>
+ <PyFunc><![CDATA[ Branch = "Odd" ]]></PyFunc>
+ <PyFunc><![CDATA[ return a & 1,1-(a&1),a,Branch,0 ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 11:50:18</creation-date>
+ <lastmodification-date>13/1/2005 - 11:50:18</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>195</x-position>
+ <y-position>129</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>EndOfSwitch</node-name>
+ <kind>7</kind>
+ <coupled-node>Switch</coupled-node>
+ <service>
+<service-name>EndOfSwitch</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>a</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>string</inParameter-type>
+ <inParameter-name>Branch</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>a</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>EndOfSwitch</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def EndOfSwitch(a,Branch) : ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep(1) ]]></PyFunc>
+ <PyFunc><![CDATA[ return a ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 11:50:18</creation-date>
+ <lastmodification-date>13/1/2005 - 11:50:18</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>882</x-position>
+ <y-position>194</y-position> </node> </node-list>
+ <link-list>
+<link>
+<fromnode-name>IsOdd</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>EmptyNode</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>646</x>
+ <y>78</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>IsEven</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>EndOfSwitch</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>PrintOdd</fromnode-name>
+ <fromserviceparameter-name>Branch</fromserviceparameter-name>
+ <tonode-name>EmptyNode</tonode-name>
+ <toserviceparameter-name>Branch</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>PrintEven</fromnode-name>
+ <fromserviceparameter-name>Branch</fromserviceparameter-name>
+ <tonode-name>EndOfSwitch</tonode-name>
+ <toserviceparameter-name>Branch</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>EmptyNode</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>EndOfSwitch</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>EmptyNode</fromnode-name>
+ <fromserviceparameter-name>Branch</fromserviceparameter-name>
+ <tonode-name>EndOfSwitch</tonode-name>
+ <toserviceparameter-name>Branch</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>InitLoopSwitch</fromnode-name>
+ <fromserviceparameter-name>DoLoop</fromserviceparameter-name>
+ <tonode-name>EndOfInitLoopSwitch</tonode-name>
+ <toserviceparameter-name>DoLoop</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>InitLoopSwitch</fromnode-name>
+ <fromserviceparameter-name>Index</fromserviceparameter-name>
+ <tonode-name>Switch</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>InitLoopSwitch</fromnode-name>
+ <fromserviceparameter-name>Min</fromserviceparameter-name>
+ <tonode-name>EndOfInitLoopSwitch</tonode-name>
+ <toserviceparameter-name>Min</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>InitLoopSwitch</fromnode-name>
+ <fromserviceparameter-name>Max</fromserviceparameter-name>
+ <tonode-name>EndOfInitLoopSwitch</tonode-name>
+ <toserviceparameter-name>Max</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>EndOfInitLoopSwitch</fromnode-name>
+ <fromserviceparameter-name>DoLoop</fromserviceparameter-name>
+ <tonode-name>InitLoopSwitch</tonode-name>
+ <toserviceparameter-name>DoLoop</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>Odd</fromserviceparameter-name>
+ <tonode-name>IsOdd</tonode-name>
+ <toserviceparameter-name>Gate</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>401</x>
+ <y>101</y> </coord>
+ <coord>
+<x>401</x>
+ <y>160</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>Odd</fromserviceparameter-name>
+ <tonode-name>PrintOdd</tonode-name>
+ <toserviceparameter-name>Gate</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>401</x>
+ <y>245</y> </coord>
+ <coord>
+<x>401</x>
+ <y>159</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>Even</fromserviceparameter-name>
+ <tonode-name>IsEven</tonode-name>
+ <toserviceparameter-name>Gate</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>392</x>
+ <y>533</y> </coord>
+ <coord>
+<x>392</x>
+ <y>182</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>Even</fromserviceparameter-name>
+ <tonode-name>PrintEven</tonode-name>
+ <toserviceparameter-name>Gate</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>392</x>
+ <y>403</y> </coord>
+ <coord>
+<x>392</x>
+ <y>181</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>IsOdd</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>382</x>
+ <y>78</y> </coord>
+ <coord>
+<x>382</x>
+ <y>199</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>IsEven</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>381</x>
+ <y>509</y> </coord>
+ <coord>
+<x>382</x>
+ <y>200</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>PrintOdd</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>PrintEven</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>381</x>
+ <y>361</y> </coord>
+ <coord>
+<x>382</x>
+ <y>200</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>Branch</fromserviceparameter-name>
+ <tonode-name>PrintOdd</tonode-name>
+ <toserviceparameter-name>Branch</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>Branch</fromserviceparameter-name>
+ <tonode-name>PrintEven</tonode-name>
+ <toserviceparameter-name>Branch</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>369</x>
+ <y>381</y> </coord>
+ <coord>
+<x>369</x>
+ <y>219</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>Default</fromserviceparameter-name>
+ <tonode-name>EndOfSwitch</tonode-name>
+ <toserviceparameter-name>Default</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>EndOfSwitch</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>EndOfInitLoopSwitch</tonode-name>
+ <toserviceparameter-name>Index</toserviceparameter-name>
+ <coord-list/> </link> </link-list>
+ <data-list>
+<data>
+<fromnode-name>GraphSwitchCheck</fromnode-name>
+ <fromserviceparameter-name>InitLoopSwitch__Index</fromserviceparameter-name>
+ <tonode-name>InitLoopSwitch</tonode-name>
+ <toserviceparameter-name>Index</toserviceparameter-name>
+ <data-value>
+<value-type>3</value-type>
+ <value>0</value> </data-value>
+ <coord-list/> </data>
+ <data>
+<fromnode-name>GraphSwitchCheck</fromnode-name>
+ <fromserviceparameter-name>InitLoopSwitch__Min</fromserviceparameter-name>
+ <tonode-name>InitLoopSwitch</tonode-name>
+ <toserviceparameter-name>Min</toserviceparameter-name>
+ <data-value>
+<value-type>3</value-type>
+ <value>-5</value> </data-value>
+ <coord-list/> </data>
+ <data>
+<fromnode-name>GraphSwitchCheck</fromnode-name>
+ <fromserviceparameter-name>InitLoopSwitch__Max</fromserviceparameter-name>
+ <tonode-name>InitLoopSwitch</tonode-name>
+ <toserviceparameter-name>Max</toserviceparameter-name>
+ <data-value>
+<value-type>3</value-type>
+ <value>10</value> </data-value>
+ <coord-list/> </data> </data-list> </dataflow></supergraph>
--- /dev/null
+
+# Generated python file of Graph GraphSwitchCheckDefault
+
+from SuperV import *
+
+# Graph creation of GraphSwitchCheckDefault
+def DefGraphSwitchCheckDefault() :
+ GraphSwitchCheckDefault = Graph( 'GraphSwitchCheckDefault' )
+ GraphSwitchCheckDefault.SetName( 'GraphSwitchCheckDefault' )
+ GraphSwitchCheckDefault.SetAuthor( 'JR' )
+ GraphSwitchCheckDefault.SetComment( '' )
+ GraphSwitchCheckDefault.Coords( 0 , 0 )
+
+ # Creation of Factory Nodes
+
+ # Creation of InLine Nodes
+ PyIsOdd = []
+ PyIsOdd.append( 'from time import * ' )
+ PyIsOdd.append( 'def IsOdd(a) : ' )
+ PyIsOdd.append( ' print a,"IsOdd (GraphSwitch)" ' )
+ PyIsOdd.append( ' sleep( 1 ) ' )
+ PyIsOdd.append( ' return a ' )
+ IsOdd = GraphSwitchCheckDefault.INode( 'IsOdd' , PyIsOdd )
+ IsOdd.SetName( 'IsOdd' )
+ IsOdd.SetAuthor( '' )
+ IsOdd.SetComment( 'Python function' )
+ IsOdd.Coords( 415 , 7 )
+ IIsOdda = IsOdd.InPort( 'a' , 'long' )
+ IIsOddGate = IsOdd.GetInPort( 'Gate' )
+ OIsOdda = IsOdd.OutPort( 'a' , 'long' )
+ OIsOddGate = IsOdd.GetOutPort( 'Gate' )
+
+ PyIsEven = []
+ PyIsEven.append( 'from time import * ' )
+ PyIsEven.append( 'def IsEven(a) : ' )
+ PyIsEven.append( ' print a,"IsEven (GraphSwitch)" ' )
+ PyIsEven.append( ' sleep( 1 ) ' )
+ PyIsEven.append( ' return a ' )
+ IsEven = GraphSwitchCheckDefault.INode( 'IsEven' , PyIsEven )
+ IsEven.SetName( 'IsEven' )
+ IsEven.SetAuthor( '' )
+ IsEven.SetComment( 'Compute Node' )
+ IsEven.Coords( 421 , 438 )
+ IIsEvena = IsEven.InPort( 'a' , 'long' )
+ IIsEvenGate = IsEven.GetInPort( 'Gate' )
+ OIsEvena = IsEven.OutPort( 'a' , 'long' )
+ OIsEvenGate = IsEven.GetOutPort( 'Gate' )
+
+ PyPrintOdd = []
+ PyPrintOdd.append( 'from time import * ' )
+ PyPrintOdd.append( 'def Print(a,Branch) : ' )
+ PyPrintOdd.append( ' print "Print ",a,Branch ' )
+ PyPrintOdd.append( ' sleep(1) ' )
+ PyPrintOdd.append( ' return Branch ' )
+ PrintOdd = GraphSwitchCheckDefault.INode( 'Print' , PyPrintOdd )
+ PrintOdd.SetName( 'PrintOdd' )
+ PrintOdd.SetAuthor( '' )
+ PrintOdd.SetComment( 'Compute Node' )
+ PrintOdd.Coords( 415 , 130 )
+ IPrintOdda = PrintOdd.InPort( 'a' , 'long' )
+ IPrintOddBranch = PrintOdd.InPort( 'Branch' , 'string' )
+ IPrintOddGate = PrintOdd.GetInPort( 'Gate' )
+ OPrintOddBranch = PrintOdd.OutPort( 'Branch' , 'string' )
+ OPrintOddGate = PrintOdd.GetOutPort( 'Gate' )
+
+ PyPrintEven = []
+ PyPrintEven.append( 'from time import * ' )
+ PyPrintEven.append( 'def Print_1(a,Branch) : ' )
+ PyPrintEven.append( ' print "Print ",a,Branch ' )
+ PyPrintEven.append( ' sleep(1) ' )
+ PyPrintEven.append( ' return Branch ' )
+ PrintEven = GraphSwitchCheckDefault.INode( 'Print_1' , PyPrintEven )
+ PrintEven.SetName( 'PrintEven' )
+ PrintEven.SetAuthor( '' )
+ PrintEven.SetComment( 'Compute Node' )
+ PrintEven.Coords( 423 , 289 )
+ IPrintEvena = PrintEven.InPort( 'a' , 'long' )
+ IPrintEvenBranch = PrintEven.InPort( 'Branch' , 'string' )
+ IPrintEvenGate = PrintEven.GetInPort( 'Gate' )
+ OPrintEvenBranch = PrintEven.OutPort( 'Branch' , 'string' )
+ OPrintEvenGate = PrintEven.GetOutPort( 'Gate' )
+
+ PyEmptyNode = []
+ PyEmptyNode.append( 'from time import * ' )
+ PyEmptyNode.append( 'def EmptyNode(a,Branch) : ' )
+ PyEmptyNode.append( ' sleep(1) ' )
+ PyEmptyNode.append( ' return a,Branch ' )
+ EmptyNode = GraphSwitchCheckDefault.INode( 'EmptyNode' , PyEmptyNode )
+ EmptyNode.SetName( 'EmptyNode' )
+ EmptyNode.SetAuthor( '' )
+ EmptyNode.SetComment( 'Compute Node' )
+ EmptyNode.Coords( 652 , 110 )
+ IEmptyNodea = EmptyNode.InPort( 'a' , 'long' )
+ IEmptyNodeBranch = EmptyNode.InPort( 'Branch' , 'string' )
+ IEmptyNodeGate = EmptyNode.GetInPort( 'Gate' )
+ OEmptyNodea = EmptyNode.OutPort( 'a' , 'long' )
+ OEmptyNodeBranch = EmptyNode.OutPort( 'Branch' , 'string' )
+ OEmptyNodeGate = EmptyNode.GetOutPort( 'Gate' )
+
+ PyDefault = []
+ PyDefault.append( 'from time import * ' )
+ PyDefault.append( 'def Default(a,Branch) : ' )
+ PyDefault.append( ' sleep(1) ' )
+ PyDefault.append( ' return a,Branch ' )
+ Default = GraphSwitchCheckDefault.INode( 'Default' , PyDefault )
+ Default.SetName( 'Default' )
+ Default.SetAuthor( '' )
+ Default.SetComment( 'Compute Node' )
+ Default.Coords( 421 , 592 )
+ IDefaulta = Default.InPort( 'a' , 'long' )
+ IDefaultBranch = Default.InPort( 'Branch' , 'string' )
+ IDefaultGate = Default.GetInPort( 'Gate' )
+ ODefaulta = Default.OutPort( 'a' , 'long' )
+ ODefaultBranch = Default.OutPort( 'Branch' , 'string' )
+ ODefaultGate = Default.GetOutPort( 'Gate' )
+
+ # Creation of Loop Nodes
+ PyInitLoopSwitch = []
+ PyInitLoopSwitch.append( 'def InitLoop(Index,Min,Max) : ' )
+ PyInitLoopSwitch.append( ' Index = Max ' )
+ PyInitLoopSwitch.append( ' return Index,Min,Max ' )
+ PyMoreInitLoopSwitch = []
+ PyMoreInitLoopSwitch.append( 'from time import * ' )
+ PyMoreInitLoopSwitch.append( 'def MoreLoop(Index,Min,Max) : ' )
+ PyMoreInitLoopSwitch.append( ' sleep(1) ' )
+ PyMoreInitLoopSwitch.append( ' if Index >= Min : ' )
+ PyMoreInitLoopSwitch.append( ' DoLoop = 1 ' )
+ PyMoreInitLoopSwitch.append( ' else : ' )
+ PyMoreInitLoopSwitch.append( ' DoLoop = 0 ' )
+ PyMoreInitLoopSwitch.append( ' return DoLoop,Index,Min,Max ' )
+ PyNextInitLoopSwitch = []
+ PyNextInitLoopSwitch.append( 'def NextLoop(Index,Min,Max) : ' )
+ PyNextInitLoopSwitch.append( ' Index = Index - 1 ' )
+ PyNextInitLoopSwitch.append( ' return Index,Min,Max ' )
+ InitLoopSwitch,EndOfInitLoopSwitch = GraphSwitchCheckDefault.LNode( 'InitLoop' , PyInitLoopSwitch , 'MoreLoop' , PyMoreInitLoopSwitch , 'NextLoop' , PyNextInitLoopSwitch )
+ EndOfInitLoopSwitch.SetName( 'EndOfInitLoopSwitch' )
+ EndOfInitLoopSwitch.SetAuthor( '' )
+ EndOfInitLoopSwitch.SetComment( 'Compute Node' )
+ EndOfInitLoopSwitch.Coords( 1074 , 194 )
+ PyEndOfInitLoopSwitch = []
+ PyEndOfInitLoopSwitch.append( 'from time import * ' )
+ PyEndOfInitLoopSwitch.append( 'def EndOfInitLoopSwitch(DoLoop,Index,Min,Max) : ' )
+ PyEndOfInitLoopSwitch.append( ' sleep(1) ' )
+ PyEndOfInitLoopSwitch.append( ' return DoLoop,Index,Min,Max ' )
+ EndOfInitLoopSwitch.SetPyFunction( 'EndOfInitLoopSwitch' , PyEndOfInitLoopSwitch )
+ IInitLoopSwitchDoLoop = InitLoopSwitch.GetInPort( 'DoLoop' )
+ IInitLoopSwitchIndex = InitLoopSwitch.InPort( 'Index' , 'long' )
+ IInitLoopSwitchMin = InitLoopSwitch.InPort( 'Min' , 'long' )
+ IInitLoopSwitchMax = InitLoopSwitch.InPort( 'Max' , 'long' )
+ IInitLoopSwitchGate = InitLoopSwitch.GetInPort( 'Gate' )
+ OInitLoopSwitchDoLoop = InitLoopSwitch.GetOutPort( 'DoLoop' )
+ OInitLoopSwitchIndex = InitLoopSwitch.GetOutPort( 'Index' )
+ OInitLoopSwitchMin = InitLoopSwitch.GetOutPort( 'Min' )
+ OInitLoopSwitchMax = InitLoopSwitch.GetOutPort( 'Max' )
+ IEndOfInitLoopSwitchDoLoop = EndOfInitLoopSwitch.GetInPort( 'DoLoop' )
+ IEndOfInitLoopSwitchIndex = EndOfInitLoopSwitch.GetInPort( 'Index' )
+ IEndOfInitLoopSwitchMin = EndOfInitLoopSwitch.GetInPort( 'Min' )
+ IEndOfInitLoopSwitchMax = EndOfInitLoopSwitch.GetInPort( 'Max' )
+ IEndOfInitLoopSwitchGate = EndOfInitLoopSwitch.GetInPort( 'Gate' )
+ OEndOfInitLoopSwitchDoLoop = EndOfInitLoopSwitch.GetOutPort( 'DoLoop' )
+ OEndOfInitLoopSwitchIndex = EndOfInitLoopSwitch.GetOutPort( 'Index' )
+ OEndOfInitLoopSwitchMin = EndOfInitLoopSwitch.GetOutPort( 'Min' )
+ OEndOfInitLoopSwitchMax = EndOfInitLoopSwitch.GetOutPort( 'Max' )
+ OEndOfInitLoopSwitchGate = EndOfInitLoopSwitch.GetOutPort( 'Gate' )
+ InitLoopSwitch.SetName( 'InitLoopSwitch' )
+ InitLoopSwitch.SetAuthor( '' )
+ InitLoopSwitch.SetComment( 'Compute Node' )
+ InitLoopSwitch.Coords( 10 , 129 )
+
+ # Creation of Switch Nodes
+ PySwitch = []
+ PySwitch.append( 'from time import * ' )
+ PySwitch.append( 'def Switch(a) : ' )
+ PySwitch.append( ' sleep(1) ' )
+ PySwitch.append( ' Branch = "Negative or null" ' )
+ PySwitch.append( ' if a <= 0 : ' )
+ PySwitch.append( ' return 0,0,a,Branch,1 ' )
+ PySwitch.append( ' if ( a & 1 ) == 0 : ' )
+ PySwitch.append( ' Branch = "Even" ' )
+ PySwitch.append( ' else : ' )
+ PySwitch.append( ' Branch = "Odd" ' )
+ PySwitch.append( ' return a & 1,1-(a&1),a,Branch,0 ' )
+ Switch,EndOfSwitch = GraphSwitchCheckDefault.SNode( 'Switch' , PySwitch )
+ EndOfSwitch.SetName( 'EndOfSwitch' )
+ EndOfSwitch.SetAuthor( '' )
+ EndOfSwitch.SetComment( 'Compute Node' )
+ EndOfSwitch.Coords( 882 , 194 )
+ PyEndOfSwitch = []
+ PyEndOfSwitch.append( 'from time import * ' )
+ PyEndOfSwitch.append( 'def EndOfSwitch(a,Branch) : ' )
+ PyEndOfSwitch.append( ' sleep(1) ' )
+ PyEndOfSwitch.append( ' return a ' )
+ EndOfSwitch.SetPyFunction( 'EndOfSwitch' , PyEndOfSwitch )
+ IEndOfSwitcha = EndOfSwitch.InPort( 'a' , 'long' )
+ IEndOfSwitchBranch = EndOfSwitch.InPort( 'Branch' , 'string' )
+ IEndOfSwitchDefault = EndOfSwitch.GetInPort( 'Default' )
+ OEndOfSwitcha = EndOfSwitch.OutPort( 'a' , 'long' )
+ OEndOfSwitchGate = EndOfSwitch.GetOutPort( 'Gate' )
+ Switch.SetName( 'Switch' )
+ Switch.SetAuthor( '' )
+ Switch.SetComment( 'Compute Node' )
+ Switch.Coords( 190 , 129 )
+ ISwitcha = Switch.InPort( 'a' , 'long' )
+ ISwitchGate = Switch.GetInPort( 'Gate' )
+ OSwitchOdd = Switch.OutPort( 'Odd' , 'long' )
+ OSwitchEven = Switch.OutPort( 'Even' , 'int' )
+ OSwitcha = Switch.OutPort( 'a' , 'int' )
+ OSwitchBranch = Switch.OutPort( 'Branch' , 'string' )
+ OSwitchdefault = Switch.OutPort( 'default' , 'boolean' )
+ OSwitchDefault = Switch.GetOutPort( 'Default' )
+
+ # Creation of Links
+ LIsOddaEmptyNodea = GraphSwitchCheckDefault.Link( OIsOdda , IEmptyNodea )
+ LIsOddaEmptyNodea.AddCoord( 1 , 646 , 78 )
+
+ LIsEvenaEndOfSwitcha = GraphSwitchCheckDefault.Link( OIsEvena , IEndOfSwitcha )
+
+ LPrintOddBranchEmptyNodeBranch = GraphSwitchCheckDefault.Link( OPrintOddBranch , IEmptyNodeBranch )
+
+ LPrintEvenBranchEndOfSwitchBranch = GraphSwitchCheckDefault.Link( OPrintEvenBranch , IEndOfSwitchBranch )
+
+ LEmptyNodeaEndOfSwitcha = GraphSwitchCheckDefault.Link( OEmptyNodea , IEndOfSwitcha )
+
+ LEmptyNodeBranchEndOfSwitchBranch = GraphSwitchCheckDefault.Link( OEmptyNodeBranch , IEndOfSwitchBranch )
+
+ LDefaultaEndOfSwitcha = GraphSwitchCheckDefault.Link( ODefaulta , IEndOfSwitcha )
+
+ LDefaultBranchEndOfSwitchBranch = GraphSwitchCheckDefault.Link( ODefaultBranch , IEndOfSwitchBranch )
+
+ LInitLoopSwitchIndexSwitcha = GraphSwitchCheckDefault.Link( OInitLoopSwitchIndex , ISwitcha )
+
+ LInitLoopSwitchMinEndOfInitLoopSwitchMin = GraphSwitchCheckDefault.Link( OInitLoopSwitchMin , IEndOfInitLoopSwitchMin )
+
+ LInitLoopSwitchMaxEndOfInitLoopSwitchMax = GraphSwitchCheckDefault.Link( OInitLoopSwitchMax , IEndOfInitLoopSwitchMax )
+
+ LSwitchOddIsOddGate = GraphSwitchCheckDefault.Link( OSwitchOdd , IIsOddGate )
+ LSwitchOddIsOddGate.AddCoord( 1 , 401 , 101 )
+ LSwitchOddIsOddGate.AddCoord( 2 , 401 , 160 )
+
+ LSwitchOddPrintOddGate = GraphSwitchCheckDefault.Link( OSwitchOdd , IPrintOddGate )
+ LSwitchOddPrintOddGate.AddCoord( 1 , 401 , 245 )
+ LSwitchOddPrintOddGate.AddCoord( 2 , 401 , 159 )
+
+ LSwitchEvenIsEvenGate = GraphSwitchCheckDefault.Link( OSwitchEven , IIsEvenGate )
+ LSwitchEvenIsEvenGate.AddCoord( 1 , 392 , 533 )
+ LSwitchEvenIsEvenGate.AddCoord( 2 , 392 , 182 )
+
+ LSwitchEvenPrintEvenGate = GraphSwitchCheckDefault.Link( OSwitchEven , IPrintEvenGate )
+ LSwitchEvenPrintEvenGate.AddCoord( 1 , 392 , 403 )
+ LSwitchEvenPrintEvenGate.AddCoord( 2 , 392 , 181 )
+
+ LSwitchaIsOdda = GraphSwitchCheckDefault.Link( OSwitcha , IIsOdda )
+ LSwitchaIsOdda.AddCoord( 1 , 382 , 78 )
+ LSwitchaIsOdda.AddCoord( 2 , 382 , 199 )
+
+ LSwitchaIsEvena = GraphSwitchCheckDefault.Link( OSwitcha , IIsEvena )
+ LSwitchaIsEvena.AddCoord( 1 , 381 , 509 )
+ LSwitchaIsEvena.AddCoord( 2 , 382 , 200 )
+
+ LSwitchaPrintOdda = GraphSwitchCheckDefault.Link( OSwitcha , IPrintOdda )
+
+ LSwitchaPrintEvena = GraphSwitchCheckDefault.Link( OSwitcha , IPrintEvena )
+ LSwitchaPrintEvena.AddCoord( 1 , 381 , 361 )
+ LSwitchaPrintEvena.AddCoord( 2 , 382 , 200 )
+
+ LSwitchaDefaulta = GraphSwitchCheckDefault.Link( OSwitcha , IDefaulta )
+ LSwitchaDefaulta.AddCoord( 1 , 382 , 663 )
+ LSwitchaDefaulta.AddCoord( 2 , 382 , 199 )
+
+ LSwitchBranchPrintOddBranch = GraphSwitchCheckDefault.Link( OSwitchBranch , IPrintOddBranch )
+
+ LSwitchBranchPrintEvenBranch = GraphSwitchCheckDefault.Link( OSwitchBranch , IPrintEvenBranch )
+ LSwitchBranchPrintEvenBranch.AddCoord( 1 , 369 , 381 )
+ LSwitchBranchPrintEvenBranch.AddCoord( 2 , 369 , 219 )
+
+ LSwitchBranchDefaultBranch = GraphSwitchCheckDefault.Link( OSwitchBranch , IDefaultBranch )
+ LSwitchBranchDefaultBranch.AddCoord( 1 , 370 , 683 )
+ LSwitchBranchDefaultBranch.AddCoord( 2 , 370 , 220 )
+
+ LSwitchDefaultDefaultGate = GraphSwitchCheckDefault.Link( OSwitchDefault , IDefaultGate )
+ LSwitchDefaultDefaultGate.AddCoord( 1 , 360 , 707 )
+ LSwitchDefaultDefaultGate.AddCoord( 2 , 360 , 263 )
+
+ LEndOfSwitchaEndOfInitLoopSwitchIndex = GraphSwitchCheckDefault.Link( OEndOfSwitcha , IEndOfInitLoopSwitchIndex )
+
+ # Input datas
+ IInitLoopSwitchIndex.Input( 0 )
+ IInitLoopSwitchMin.Input( -5 )
+ IInitLoopSwitchMax.Input( 10 )
+
+ # Output Ports of the graph
+ #OEndOfInitLoopSwitchIndex = EndOfInitLoopSwitch.GetOutPort( 'Index' )
+ #OEndOfInitLoopSwitchMin = EndOfInitLoopSwitch.GetOutPort( 'Min' )
+ #OEndOfInitLoopSwitchMax = EndOfInitLoopSwitch.GetOutPort( 'Max' )
+ #OSwitchdefault = Switch.GetOutPort( 'default' )
+ return GraphSwitchCheckDefault
+
+
+GraphSwitchCheckDefault = DefGraphSwitchCheckDefault()
--- /dev/null
+<!DOCTYPE SuperGraph>
+<supergraph>
+<dataflow>
+<info-list>
+<node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>GraphSwitchCheckDefault</node-name>
+ <kind>1</kind>
+ <coupled-node>?</coupled-node>
+ <service>
+<service-name>GraphSwitchCheck_2</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>InitLoopSwitch__Index</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>InitLoopSwitch__Min</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>InitLoopSwitch__Max</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>EndOfInitLoopSwitch__Index</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>EndOfInitLoopSwitch__Min</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>EndOfInitLoopSwitch__Max</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>boolean</outParameter-type>
+ <outParameter-name>Switch__default</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list/>
+ <creation-date>13/1/2005 - 12:21:43</creation-date>
+ <lastmodification-date>13/1/2005 - 12:23:17</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>JR</author>
+ <container>?</container>
+ <comment>?</comment>
+ <x-position>0</x-position>
+ <y-position>0</y-position> </node> </info-list>
+ <node-list>
+<node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>IsOdd</node-name>
+ <kind>3</kind>
+ <coupled-node>?</coupled-node>
+ <service>
+<service-name>IsOdd</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>a</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>a</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>IsOdd</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def IsOdd(a) : ]]></PyFunc>
+ <PyFunc><![CDATA[ print a,"IsOdd (GraphSwitch)" ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep( 1 ) ]]></PyFunc>
+ <PyFunc><![CDATA[ return a ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 12:23:17</creation-date>
+ <lastmodification-date>13/1/2005 - 12:23:17</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Python function</comment>
+ <x-position>415</x-position>
+ <y-position>7</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>IsEven</node-name>
+ <kind>3</kind>
+ <coupled-node>?</coupled-node>
+ <service>
+<service-name>IsEven</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>a</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>a</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>IsEven</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def IsEven(a) : ]]></PyFunc>
+ <PyFunc><![CDATA[ print a,"IsEven (GraphSwitch)" ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep( 1 ) ]]></PyFunc>
+ <PyFunc><![CDATA[ return a ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 12:23:17</creation-date>
+ <lastmodification-date>13/1/2005 - 12:23:17</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>421</x-position>
+ <y-position>438</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>PrintOdd</node-name>
+ <kind>3</kind>
+ <coupled-node>?</coupled-node>
+ <service>
+<service-name>PrintOdd</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>a</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>string</inParameter-type>
+ <inParameter-name>Branch</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>string</outParameter-type>
+ <outParameter-name>Branch</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>Print</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def Print(a,Branch) : ]]></PyFunc>
+ <PyFunc><![CDATA[ print "Print ",a,Branch ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep(1) ]]></PyFunc>
+ <PyFunc><![CDATA[ return Branch ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 12:23:17</creation-date>
+ <lastmodification-date>13/1/2005 - 12:23:17</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>415</x-position>
+ <y-position>130</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>PrintEven</node-name>
+ <kind>3</kind>
+ <coupled-node>?</coupled-node>
+ <service>
+<service-name>PrintEven</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>a</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>string</inParameter-type>
+ <inParameter-name>Branch</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>string</outParameter-type>
+ <outParameter-name>Branch</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>Print_1</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def Print_1(a,Branch) : ]]></PyFunc>
+ <PyFunc><![CDATA[ print "Print ",a,Branch ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep(1) ]]></PyFunc>
+ <PyFunc><![CDATA[ return Branch ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 12:23:17</creation-date>
+ <lastmodification-date>13/1/2005 - 12:23:17</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>423</x-position>
+ <y-position>289</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>EmptyNode</node-name>
+ <kind>3</kind>
+ <coupled-node>?</coupled-node>
+ <service>
+<service-name>EmptyNode</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>a</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>string</inParameter-type>
+ <inParameter-name>Branch</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>a</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>string</outParameter-type>
+ <outParameter-name>Branch</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>EmptyNode</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def EmptyNode(a,Branch) : ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep(1) ]]></PyFunc>
+ <PyFunc><![CDATA[ return a,Branch ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 12:23:17</creation-date>
+ <lastmodification-date>13/1/2005 - 12:23:17</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>652</x-position>
+ <y-position>110</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>Default</node-name>
+ <kind>3</kind>
+ <coupled-node>?</coupled-node>
+ <service>
+<service-name>Default</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>a</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>string</inParameter-type>
+ <inParameter-name>Branch</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>a</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>string</outParameter-type>
+ <outParameter-name>Branch</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>Default</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def Default(a,Branch) : ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep(1) ]]></PyFunc>
+ <PyFunc><![CDATA[ return a,Branch ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 12:23:17</creation-date>
+ <lastmodification-date>13/1/2005 - 12:23:17</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>421</x-position>
+ <y-position>592</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>InitLoopSwitch</node-name>
+ <kind>4</kind>
+ <coupled-node>EndOfInitLoopSwitch</coupled-node>
+ <service>
+<service-name>InitLoopSwitch</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>Index</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>Min</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>Max</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>Index</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>Min</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>Max</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>InitLoop</FuncName>
+ <PyFunc><![CDATA[def InitLoop(Index,Min,Max) : ]]></PyFunc>
+ <PyFunc><![CDATA[ Index = Max ]]></PyFunc>
+ <PyFunc><![CDATA[ return Index,Min,Max ]]></PyFunc> </PyFunction>
+ <PyFunction>
+<FuncName>MoreLoop</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def MoreLoop(Index,Min,Max) : ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep(1) ]]></PyFunc>
+ <PyFunc><![CDATA[ if Index >= Min : ]]></PyFunc>
+ <PyFunc><![CDATA[ DoLoop = 1 ]]></PyFunc>
+ <PyFunc><![CDATA[ else : ]]></PyFunc>
+ <PyFunc><![CDATA[ DoLoop = 0 ]]></PyFunc>
+ <PyFunc><![CDATA[ return DoLoop,Index,Min,Max ]]></PyFunc> </PyFunction>
+ <PyFunction>
+<FuncName>NextLoop</FuncName>
+ <PyFunc><![CDATA[def NextLoop(Index,Min,Max) : ]]></PyFunc>
+ <PyFunc><![CDATA[ Index = Index - 1 ]]></PyFunc>
+ <PyFunc><![CDATA[ return Index,Min,Max ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 12:23:17</creation-date>
+ <lastmodification-date>13/1/2005 - 12:23:17</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>10</x-position>
+ <y-position>129</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>EndOfInitLoopSwitch</node-name>
+ <kind>5</kind>
+ <coupled-node>InitLoopSwitch</coupled-node>
+ <service>
+<service-name>EndOfInitLoopSwitch</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>Index</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>Min</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>Max</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>Index</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>Min</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>Max</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>EndOfInitLoopSwitch</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def EndOfInitLoopSwitch(DoLoop,Index,Min,Max) : ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep(1) ]]></PyFunc>
+ <PyFunc><![CDATA[ return DoLoop,Index,Min,Max ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 12:23:17</creation-date>
+ <lastmodification-date>13/1/2005 - 12:23:17</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>1074</x-position>
+ <y-position>194</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>Switch</node-name>
+ <kind>6</kind>
+ <coupled-node>EndOfSwitch</coupled-node>
+ <service>
+<service-name>Switch</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>a</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>Odd</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>int</outParameter-type>
+ <outParameter-name>Even</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>int</outParameter-type>
+ <outParameter-name>a</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>string</outParameter-type>
+ <outParameter-name>Branch</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>boolean</outParameter-type>
+ <outParameter-name>default</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>Switch</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def Switch(a) : ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep(1) ]]></PyFunc>
+ <PyFunc><![CDATA[ Branch = "Negative or null" ]]></PyFunc>
+ <PyFunc><![CDATA[ if a <= 0 : ]]></PyFunc>
+ <PyFunc><![CDATA[ return 0,0,a,Branch,1 ]]></PyFunc>
+ <PyFunc><![CDATA[ if ( a & 1 ) == 0 : ]]></PyFunc>
+ <PyFunc><![CDATA[ Branch = "Even" ]]></PyFunc>
+ <PyFunc><![CDATA[ else : ]]></PyFunc>
+ <PyFunc><![CDATA[ Branch = "Odd" ]]></PyFunc>
+ <PyFunc><![CDATA[ return a & 1,1-(a&1),a,Branch,0 ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 12:23:17</creation-date>
+ <lastmodification-date>13/1/2005 - 12:23:17</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>190</x-position>
+ <y-position>129</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>EndOfSwitch</node-name>
+ <kind>7</kind>
+ <coupled-node>Switch</coupled-node>
+ <service>
+<service-name>EndOfSwitch</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>a</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>string</inParameter-type>
+ <inParameter-name>Branch</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>a</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>EndOfSwitch</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def EndOfSwitch(a,Branch) : ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep(1) ]]></PyFunc>
+ <PyFunc><![CDATA[ return a ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 12:23:17</creation-date>
+ <lastmodification-date>13/1/2005 - 12:23:17</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>882</x-position>
+ <y-position>194</y-position> </node> </node-list>
+ <link-list>
+<link>
+<fromnode-name>IsOdd</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>EmptyNode</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>646</x>
+ <y>78</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>IsEven</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>EndOfSwitch</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>PrintOdd</fromnode-name>
+ <fromserviceparameter-name>Branch</fromserviceparameter-name>
+ <tonode-name>EmptyNode</tonode-name>
+ <toserviceparameter-name>Branch</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>PrintEven</fromnode-name>
+ <fromserviceparameter-name>Branch</fromserviceparameter-name>
+ <tonode-name>EndOfSwitch</tonode-name>
+ <toserviceparameter-name>Branch</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>EmptyNode</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>EndOfSwitch</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>EmptyNode</fromnode-name>
+ <fromserviceparameter-name>Branch</fromserviceparameter-name>
+ <tonode-name>EndOfSwitch</tonode-name>
+ <toserviceparameter-name>Branch</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>Default</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>EndOfSwitch</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>Default</fromnode-name>
+ <fromserviceparameter-name>Branch</fromserviceparameter-name>
+ <tonode-name>EndOfSwitch</tonode-name>
+ <toserviceparameter-name>Branch</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>InitLoopSwitch</fromnode-name>
+ <fromserviceparameter-name>DoLoop</fromserviceparameter-name>
+ <tonode-name>EndOfInitLoopSwitch</tonode-name>
+ <toserviceparameter-name>DoLoop</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>InitLoopSwitch</fromnode-name>
+ <fromserviceparameter-name>Index</fromserviceparameter-name>
+ <tonode-name>Switch</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>InitLoopSwitch</fromnode-name>
+ <fromserviceparameter-name>Min</fromserviceparameter-name>
+ <tonode-name>EndOfInitLoopSwitch</tonode-name>
+ <toserviceparameter-name>Min</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>InitLoopSwitch</fromnode-name>
+ <fromserviceparameter-name>Max</fromserviceparameter-name>
+ <tonode-name>EndOfInitLoopSwitch</tonode-name>
+ <toserviceparameter-name>Max</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>EndOfInitLoopSwitch</fromnode-name>
+ <fromserviceparameter-name>DoLoop</fromserviceparameter-name>
+ <tonode-name>InitLoopSwitch</tonode-name>
+ <toserviceparameter-name>DoLoop</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>Odd</fromserviceparameter-name>
+ <tonode-name>IsOdd</tonode-name>
+ <toserviceparameter-name>Gate</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>401</x>
+ <y>101</y> </coord>
+ <coord>
+<x>401</x>
+ <y>160</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>Odd</fromserviceparameter-name>
+ <tonode-name>PrintOdd</tonode-name>
+ <toserviceparameter-name>Gate</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>401</x>
+ <y>245</y> </coord>
+ <coord>
+<x>401</x>
+ <y>159</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>Even</fromserviceparameter-name>
+ <tonode-name>IsEven</tonode-name>
+ <toserviceparameter-name>Gate</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>392</x>
+ <y>533</y> </coord>
+ <coord>
+<x>392</x>
+ <y>182</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>Even</fromserviceparameter-name>
+ <tonode-name>PrintEven</tonode-name>
+ <toserviceparameter-name>Gate</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>392</x>
+ <y>403</y> </coord>
+ <coord>
+<x>392</x>
+ <y>181</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>IsOdd</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>382</x>
+ <y>78</y> </coord>
+ <coord>
+<x>382</x>
+ <y>199</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>IsEven</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>381</x>
+ <y>509</y> </coord>
+ <coord>
+<x>382</x>
+ <y>200</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>PrintOdd</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>PrintEven</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>381</x>
+ <y>361</y> </coord>
+ <coord>
+<x>382</x>
+ <y>200</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>Default</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>382</x>
+ <y>663</y> </coord>
+ <coord>
+<x>382</x>
+ <y>199</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>Branch</fromserviceparameter-name>
+ <tonode-name>PrintOdd</tonode-name>
+ <toserviceparameter-name>Branch</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>Branch</fromserviceparameter-name>
+ <tonode-name>PrintEven</tonode-name>
+ <toserviceparameter-name>Branch</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>369</x>
+ <y>381</y> </coord>
+ <coord>
+<x>369</x>
+ <y>219</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>Branch</fromserviceparameter-name>
+ <tonode-name>Default</tonode-name>
+ <toserviceparameter-name>Branch</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>370</x>
+ <y>683</y> </coord>
+ <coord>
+<x>370</x>
+ <y>220</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>Default</fromserviceparameter-name>
+ <tonode-name>Default</tonode-name>
+ <toserviceparameter-name>Gate</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>360</x>
+ <y>707</y> </coord>
+ <coord>
+<x>360</x>
+ <y>263</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>EndOfSwitch</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>EndOfInitLoopSwitch</tonode-name>
+ <toserviceparameter-name>Index</toserviceparameter-name>
+ <coord-list/> </link> </link-list>
+ <data-list>
+<data>
+<fromnode-name>GraphSwitchCheckDefault</fromnode-name>
+ <fromserviceparameter-name>InitLoopSwitch__Index</fromserviceparameter-name>
+ <tonode-name>InitLoopSwitch</tonode-name>
+ <toserviceparameter-name>Index</toserviceparameter-name>
+ <data-value>
+<value-type>3</value-type>
+ <value>0</value> </data-value>
+ <coord-list/> </data>
+ <data>
+<fromnode-name>GraphSwitchCheckDefault</fromnode-name>
+ <fromserviceparameter-name>InitLoopSwitch__Min</fromserviceparameter-name>
+ <tonode-name>InitLoopSwitch</tonode-name>
+ <toserviceparameter-name>Min</toserviceparameter-name>
+ <data-value>
+<value-type>3</value-type>
+ <value>-5</value> </data-value>
+ <coord-list/> </data>
+ <data>
+<fromnode-name>GraphSwitchCheckDefault</fromnode-name>
+ <fromserviceparameter-name>InitLoopSwitch__Max</fromserviceparameter-name>
+ <tonode-name>InitLoopSwitch</tonode-name>
+ <toserviceparameter-name>Max</toserviceparameter-name>
+ <data-value>
+<value-type>3</value-type>
+ <value>10</value> </data-value>
+ <coord-list/> </data> </data-list> </dataflow></supergraph>
--- /dev/null
+
+# Generated python file of Graph GraphSwitchCheckDefault1
+
+from SuperV import *
+
+# Graph creation of GraphSwitchCheckDefault1
+def DefGraphSwitchCheckDefault1() :
+ GraphSwitchCheckDefault1 = Graph( 'GraphSwitchCheckDefault1' )
+ GraphSwitchCheckDefault1.SetName( 'GraphSwitchCheckDefault1' )
+ GraphSwitchCheckDefault1.SetAuthor( 'JR' )
+ GraphSwitchCheckDefault1.SetComment( '' )
+ GraphSwitchCheckDefault1.Coords( 0 , 0 )
+
+ # Creation of Factory Nodes
+
+ # Creation of InLine Nodes
+ PyIsOdd = []
+ PyIsOdd.append( 'from time import * ' )
+ PyIsOdd.append( 'def IsOdd(a) : ' )
+ PyIsOdd.append( ' print a,"IsOdd (GraphSwitch)" ' )
+ PyIsOdd.append( ' sleep( 1 ) ' )
+ PyIsOdd.append( ' return a ' )
+ IsOdd = GraphSwitchCheckDefault1.INode( 'IsOdd' , PyIsOdd )
+ IsOdd.SetName( 'IsOdd' )
+ IsOdd.SetAuthor( '' )
+ IsOdd.SetComment( 'Python function' )
+ IsOdd.Coords( 415 , 7 )
+ IIsOdda = IsOdd.InPort( 'a' , 'long' )
+ IIsOddGate = IsOdd.GetInPort( 'Gate' )
+ OIsOdda = IsOdd.OutPort( 'a' , 'long' )
+ OIsOddGate = IsOdd.GetOutPort( 'Gate' )
+
+ PyIsEven = []
+ PyIsEven.append( 'from time import * ' )
+ PyIsEven.append( 'def IsEven(a) : ' )
+ PyIsEven.append( ' print a,"IsEven (GraphSwitch)" ' )
+ PyIsEven.append( ' sleep( 1 ) ' )
+ PyIsEven.append( ' return a ' )
+ IsEven = GraphSwitchCheckDefault1.INode( 'IsEven' , PyIsEven )
+ IsEven.SetName( 'IsEven' )
+ IsEven.SetAuthor( '' )
+ IsEven.SetComment( 'Compute Node' )
+ IsEven.Coords( 421 , 438 )
+ IIsEvena = IsEven.InPort( 'a' , 'long' )
+ IIsEvenGate = IsEven.GetInPort( 'Gate' )
+ OIsEvena = IsEven.OutPort( 'a' , 'long' )
+ OIsEvenGate = IsEven.GetOutPort( 'Gate' )
+
+ PyPrintOdd = []
+ PyPrintOdd.append( 'from time import * ' )
+ PyPrintOdd.append( 'def Print(a,Branch) : ' )
+ PyPrintOdd.append( ' print "Print ",a,Branch ' )
+ PyPrintOdd.append( ' sleep(1) ' )
+ PyPrintOdd.append( ' return Branch ' )
+ PrintOdd = GraphSwitchCheckDefault1.INode( 'Print' , PyPrintOdd )
+ PrintOdd.SetName( 'PrintOdd' )
+ PrintOdd.SetAuthor( '' )
+ PrintOdd.SetComment( 'Compute Node' )
+ PrintOdd.Coords( 415 , 130 )
+ IPrintOdda = PrintOdd.InPort( 'a' , 'long' )
+ IPrintOddBranch = PrintOdd.InPort( 'Branch' , 'string' )
+ IPrintOddGate = PrintOdd.GetInPort( 'Gate' )
+ OPrintOddBranch = PrintOdd.OutPort( 'Branch' , 'string' )
+ OPrintOddGate = PrintOdd.GetOutPort( 'Gate' )
+
+ PyPrintEven = []
+ PyPrintEven.append( 'from time import * ' )
+ PyPrintEven.append( 'def Print_1(a,Branch) : ' )
+ PyPrintEven.append( ' print "Print ",a,Branch ' )
+ PyPrintEven.append( ' sleep(1) ' )
+ PyPrintEven.append( ' return Branch ' )
+ PrintEven = GraphSwitchCheckDefault1.INode( 'Print_1' , PyPrintEven )
+ PrintEven.SetName( 'PrintEven' )
+ PrintEven.SetAuthor( '' )
+ PrintEven.SetComment( 'Compute Node' )
+ PrintEven.Coords( 423 , 289 )
+ IPrintEvena = PrintEven.InPort( 'a' , 'long' )
+ IPrintEvenBranch = PrintEven.InPort( 'Branch' , 'string' )
+ IPrintEvenGate = PrintEven.GetInPort( 'Gate' )
+ OPrintEvenBranch = PrintEven.OutPort( 'Branch' , 'string' )
+ OPrintEvenGate = PrintEven.GetOutPort( 'Gate' )
+
+ PyEmptyNode = []
+ PyEmptyNode.append( 'from time import * ' )
+ PyEmptyNode.append( 'def EmptyNode(a,Branch) : ' )
+ PyEmptyNode.append( ' sleep(1) ' )
+ PyEmptyNode.append( ' return a,Branch ' )
+ EmptyNode = GraphSwitchCheckDefault1.INode( 'EmptyNode' , PyEmptyNode )
+ EmptyNode.SetName( 'EmptyNode' )
+ EmptyNode.SetAuthor( '' )
+ EmptyNode.SetComment( 'Compute Node' )
+ EmptyNode.Coords( 652 , 110 )
+ IEmptyNodea = EmptyNode.InPort( 'a' , 'long' )
+ IEmptyNodeBranch = EmptyNode.InPort( 'Branch' , 'string' )
+ IEmptyNodeGate = EmptyNode.GetInPort( 'Gate' )
+ OEmptyNodea = EmptyNode.OutPort( 'a' , 'long' )
+ OEmptyNodeBranch = EmptyNode.OutPort( 'Branch' , 'string' )
+ OEmptyNodeGate = EmptyNode.GetOutPort( 'Gate' )
+
+ PyDefault = []
+ PyDefault.append( 'from time import * ' )
+ PyDefault.append( 'def Default(a,Branch) : ' )
+ PyDefault.append( ' sleep(1) ' )
+ PyDefault.append( ' return a,Branch ' )
+ Default = GraphSwitchCheckDefault1.INode( 'Default' , PyDefault )
+ Default.SetName( 'Default' )
+ Default.SetAuthor( '' )
+ Default.SetComment( 'Compute Node' )
+ Default.Coords( 421 , 592 )
+ IDefaulta = Default.InPort( 'a' , 'long' )
+ IDefaultBranch = Default.InPort( 'Branch' , 'string' )
+ IDefaultGate = Default.GetInPort( 'Gate' )
+ ODefaulta = Default.OutPort( 'a' , 'long' )
+ ODefaultBranch = Default.OutPort( 'Branch' , 'string' )
+ ODefaultGate = Default.GetOutPort( 'Gate' )
+
+ # Creation of Loop Nodes
+ PyInitLoopSwitch = []
+ PyInitLoopSwitch.append( 'def InitLoop(Index,Min,Max) : ' )
+ PyInitLoopSwitch.append( ' Index = Max ' )
+ PyInitLoopSwitch.append( ' return Index,Min,Max ' )
+ PyMoreInitLoopSwitch = []
+ PyMoreInitLoopSwitch.append( 'from time import * ' )
+ PyMoreInitLoopSwitch.append( 'def MoreLoop(Index,Min,Max) : ' )
+ PyMoreInitLoopSwitch.append( ' sleep(1) ' )
+ PyMoreInitLoopSwitch.append( ' if Index >= Min : ' )
+ PyMoreInitLoopSwitch.append( ' DoLoop = 1 ' )
+ PyMoreInitLoopSwitch.append( ' else : ' )
+ PyMoreInitLoopSwitch.append( ' DoLoop = 0 ' )
+ PyMoreInitLoopSwitch.append( ' return DoLoop,Index,Min,Max ' )
+ PyNextInitLoopSwitch = []
+ PyNextInitLoopSwitch.append( 'def NextLoop(Index,Min,Max) : ' )
+ PyNextInitLoopSwitch.append( ' Index = Index - 1 ' )
+ PyNextInitLoopSwitch.append( ' return Index,Min,Max ' )
+ InitLoopSwitch,EndOfInitLoopSwitch = GraphSwitchCheckDefault1.LNode( 'InitLoop' , PyInitLoopSwitch , 'MoreLoop' , PyMoreInitLoopSwitch , 'NextLoop' , PyNextInitLoopSwitch )
+ EndOfInitLoopSwitch.SetName( 'EndOfInitLoopSwitch' )
+ EndOfInitLoopSwitch.SetAuthor( '' )
+ EndOfInitLoopSwitch.SetComment( 'Compute Node' )
+ EndOfInitLoopSwitch.Coords( 1074 , 194 )
+ PyEndOfInitLoopSwitch = []
+ PyEndOfInitLoopSwitch.append( 'from time import * ' )
+ PyEndOfInitLoopSwitch.append( 'def EndOfInitLoopSwitch(DoLoop,Index,Min,Max) : ' )
+ PyEndOfInitLoopSwitch.append( ' sleep(1) ' )
+ PyEndOfInitLoopSwitch.append( ' return DoLoop,Index,Min,Max ' )
+ EndOfInitLoopSwitch.SetPyFunction( 'EndOfInitLoopSwitch' , PyEndOfInitLoopSwitch )
+ IInitLoopSwitchDoLoop = InitLoopSwitch.GetInPort( 'DoLoop' )
+ IInitLoopSwitchIndex = InitLoopSwitch.InPort( 'Index' , 'long' )
+ IInitLoopSwitchMin = InitLoopSwitch.InPort( 'Min' , 'long' )
+ IInitLoopSwitchMax = InitLoopSwitch.InPort( 'Max' , 'long' )
+ IInitLoopSwitchGate = InitLoopSwitch.GetInPort( 'Gate' )
+ OInitLoopSwitchDoLoop = InitLoopSwitch.GetOutPort( 'DoLoop' )
+ OInitLoopSwitchIndex = InitLoopSwitch.GetOutPort( 'Index' )
+ OInitLoopSwitchMin = InitLoopSwitch.GetOutPort( 'Min' )
+ OInitLoopSwitchMax = InitLoopSwitch.GetOutPort( 'Max' )
+ IEndOfInitLoopSwitchDoLoop = EndOfInitLoopSwitch.GetInPort( 'DoLoop' )
+ IEndOfInitLoopSwitchIndex = EndOfInitLoopSwitch.GetInPort( 'Index' )
+ IEndOfInitLoopSwitchMin = EndOfInitLoopSwitch.GetInPort( 'Min' )
+ IEndOfInitLoopSwitchMax = EndOfInitLoopSwitch.GetInPort( 'Max' )
+ IEndOfInitLoopSwitchGate = EndOfInitLoopSwitch.GetInPort( 'Gate' )
+ OEndOfInitLoopSwitchDoLoop = EndOfInitLoopSwitch.GetOutPort( 'DoLoop' )
+ OEndOfInitLoopSwitchIndex = EndOfInitLoopSwitch.GetOutPort( 'Index' )
+ OEndOfInitLoopSwitchMin = EndOfInitLoopSwitch.GetOutPort( 'Min' )
+ OEndOfInitLoopSwitchMax = EndOfInitLoopSwitch.GetOutPort( 'Max' )
+ OEndOfInitLoopSwitchGate = EndOfInitLoopSwitch.GetOutPort( 'Gate' )
+ InitLoopSwitch.SetName( 'InitLoopSwitch' )
+ InitLoopSwitch.SetAuthor( '' )
+ InitLoopSwitch.SetComment( 'Compute Node' )
+ InitLoopSwitch.Coords( 10 , 129 )
+
+ # Creation of Switch Nodes
+ PySwitch = []
+ PySwitch.append( 'from time import * ' )
+ PySwitch.append( 'def Switch(a) : ' )
+ PySwitch.append( ' sleep(1) ' )
+ PySwitch.append( ' Branch = "Negative or null" ' )
+ PySwitch.append( ' if a <= 0 : ' )
+ PySwitch.append( ' return 0,0,a,Branch,1 ' )
+ PySwitch.append( ' if ( a & 1 ) == 0 : ' )
+ PySwitch.append( ' Branch = "Even" ' )
+ PySwitch.append( ' else : ' )
+ PySwitch.append( ' Branch = "Odd" ' )
+ PySwitch.append( ' return a & 1,1-(a&1),a,Branch,0 ' )
+ Switch,EndOfSwitch = GraphSwitchCheckDefault1.SNode( 'Switch' , PySwitch )
+ EndOfSwitch.SetName( 'EndOfSwitch' )
+ EndOfSwitch.SetAuthor( '' )
+ EndOfSwitch.SetComment( 'Compute Node' )
+ EndOfSwitch.Coords( 882 , 194 )
+ PyEndOfSwitch = []
+ PyEndOfSwitch.append( 'from time import * ' )
+ PyEndOfSwitch.append( 'def EndOfSwitch(a,Branch) : ' )
+ PyEndOfSwitch.append( ' sleep(1) ' )
+ PyEndOfSwitch.append( ' return a ' )
+ EndOfSwitch.SetPyFunction( 'EndOfSwitch' , PyEndOfSwitch )
+ IEndOfSwitcha = EndOfSwitch.InPort( 'a' , 'long' )
+ IEndOfSwitchBranch = EndOfSwitch.InPort( 'Branch' , 'string' )
+ IEndOfSwitchDefault = EndOfSwitch.GetInPort( 'Default' )
+ OEndOfSwitcha = EndOfSwitch.OutPort( 'a' , 'long' )
+ OEndOfSwitchGate = EndOfSwitch.GetOutPort( 'Gate' )
+ Switch.SetName( 'Switch' )
+ Switch.SetAuthor( '' )
+ Switch.SetComment( 'Compute Node' )
+ Switch.Coords( 190 , 129 )
+ ISwitcha = Switch.InPort( 'a' , 'long' )
+ ISwitchGate = Switch.GetInPort( 'Gate' )
+ OSwitchOdd = Switch.OutPort( 'Odd' , 'long' )
+ OSwitchEven = Switch.OutPort( 'Even' , 'int' )
+ OSwitcha = Switch.OutPort( 'a' , 'int' )
+ OSwitchBranch = Switch.OutPort( 'Branch' , 'string' )
+ OSwitchdefault = Switch.OutPort( 'default' , 'boolean' )
+ OSwitchDefault = Switch.GetOutPort( 'Default' )
+
+ # Creation of Links
+ LIsOddaEmptyNodea = GraphSwitchCheckDefault1.Link( OIsOdda , IEmptyNodea )
+ LIsOddaEmptyNodea.AddCoord( 1 , 646 , 78 )
+
+ LIsEvenaEndOfSwitcha = GraphSwitchCheckDefault1.Link( OIsEvena , IEndOfSwitcha )
+
+ LPrintOddBranchEmptyNodeBranch = GraphSwitchCheckDefault1.Link( OPrintOddBranch , IEmptyNodeBranch )
+
+ LPrintEvenBranchEndOfSwitchBranch = GraphSwitchCheckDefault1.Link( OPrintEvenBranch , IEndOfSwitchBranch )
+
+ LEmptyNodeaEndOfSwitcha = GraphSwitchCheckDefault1.Link( OEmptyNodea , IEndOfSwitcha )
+
+ LEmptyNodeBranchEndOfSwitchBranch = GraphSwitchCheckDefault1.Link( OEmptyNodeBranch , IEndOfSwitchBranch )
+
+ LDefaultaEndOfSwitcha = GraphSwitchCheckDefault1.Link( ODefaulta , IEndOfSwitcha )
+
+ LDefaultBranchEndOfSwitchBranch = GraphSwitchCheckDefault1.Link( ODefaultBranch , IEndOfSwitchBranch )
+
+ LInitLoopSwitchIndexSwitcha = GraphSwitchCheckDefault1.Link( OInitLoopSwitchIndex , ISwitcha )
+
+ LInitLoopSwitchMinEndOfInitLoopSwitchMin = GraphSwitchCheckDefault1.Link( OInitLoopSwitchMin , IEndOfInitLoopSwitchMin )
+
+ LInitLoopSwitchMaxEndOfInitLoopSwitchMax = GraphSwitchCheckDefault1.Link( OInitLoopSwitchMax , IEndOfInitLoopSwitchMax )
+
+ LSwitchOddIsOddGate = GraphSwitchCheckDefault1.Link( OSwitchOdd , IIsOddGate )
+ LSwitchOddIsOddGate.AddCoord( 1 , 401 , 101 )
+ LSwitchOddIsOddGate.AddCoord( 2 , 401 , 160 )
+
+ LSwitchOddPrintOddGate = GraphSwitchCheckDefault1.Link( OSwitchOdd , IPrintOddGate )
+ LSwitchOddPrintOddGate.AddCoord( 1 , 401 , 245 )
+ LSwitchOddPrintOddGate.AddCoord( 2 , 401 , 159 )
+
+ LSwitchEvenIsEvenGate = GraphSwitchCheckDefault1.Link( OSwitchEven , IIsEvenGate )
+ LSwitchEvenIsEvenGate.AddCoord( 1 , 392 , 533 )
+ LSwitchEvenIsEvenGate.AddCoord( 2 , 392 , 182 )
+
+ LSwitchEvenPrintEvenGate = GraphSwitchCheckDefault1.Link( OSwitchEven , IPrintEvenGate )
+ LSwitchEvenPrintEvenGate.AddCoord( 1 , 392 , 403 )
+ LSwitchEvenPrintEvenGate.AddCoord( 2 , 392 , 181 )
+
+ LSwitchaIsOdda = GraphSwitchCheckDefault1.Link( OSwitcha , IIsOdda )
+ LSwitchaIsOdda.AddCoord( 1 , 382 , 78 )
+ LSwitchaIsOdda.AddCoord( 2 , 382 , 199 )
+
+ LSwitchaIsEvena = GraphSwitchCheckDefault1.Link( OSwitcha , IIsEvena )
+ LSwitchaIsEvena.AddCoord( 1 , 381 , 509 )
+ LSwitchaIsEvena.AddCoord( 2 , 382 , 200 )
+
+ LSwitchaPrintOdda = GraphSwitchCheckDefault1.Link( OSwitcha , IPrintOdda )
+
+ LSwitchaPrintEvena = GraphSwitchCheckDefault1.Link( OSwitcha , IPrintEvena )
+ LSwitchaPrintEvena.AddCoord( 1 , 381 , 361 )
+ LSwitchaPrintEvena.AddCoord( 2 , 382 , 200 )
+
+ LSwitchaDefaulta = GraphSwitchCheckDefault1.Link( OSwitcha , IDefaulta )
+ LSwitchaDefaulta.AddCoord( 1 , 382 , 663 )
+ LSwitchaDefaulta.AddCoord( 2 , 382 , 199 )
+
+ LSwitchBranchPrintOddBranch = GraphSwitchCheckDefault1.Link( OSwitchBranch , IPrintOddBranch )
+
+ LSwitchBranchPrintEvenBranch = GraphSwitchCheckDefault1.Link( OSwitchBranch , IPrintEvenBranch )
+ LSwitchBranchPrintEvenBranch.AddCoord( 1 , 369 , 381 )
+ LSwitchBranchPrintEvenBranch.AddCoord( 2 , 369 , 219 )
+
+ LSwitchBranchDefaultBranch = GraphSwitchCheckDefault1.Link( OSwitchBranch , IDefaultBranch )
+ LSwitchBranchDefaultBranch.AddCoord( 1 , 370 , 683 )
+ LSwitchBranchDefaultBranch.AddCoord( 2 , 370 , 220 )
+
+ LSwitchdefaultDefaultGate = GraphSwitchCheckDefault1.Link( OSwitchdefault , IDefaultGate )
+ LSwitchdefaultDefaultGate.AddCoord( 1 , 363 , 707 )
+ LSwitchdefaultDefaultGate.AddCoord( 2 , 362 , 239 )
+
+ LEndOfSwitchaEndOfInitLoopSwitchIndex = GraphSwitchCheckDefault1.Link( OEndOfSwitcha , IEndOfInitLoopSwitchIndex )
+
+ # Input datas
+ IInitLoopSwitchIndex.Input( 0 )
+ IInitLoopSwitchMin.Input( -5 )
+ IInitLoopSwitchMax.Input( 10 )
+
+ # Output Ports of the graph
+ #OEndOfInitLoopSwitchIndex = EndOfInitLoopSwitch.GetOutPort( 'Index' )
+ #OEndOfInitLoopSwitchMin = EndOfInitLoopSwitch.GetOutPort( 'Min' )
+ #OEndOfInitLoopSwitchMax = EndOfInitLoopSwitch.GetOutPort( 'Max' )
+ return GraphSwitchCheckDefault1
+
+
+GraphSwitchCheckDefault1 = DefGraphSwitchCheckDefault1()
--- /dev/null
+<!DOCTYPE SuperGraph>
+<supergraph>
+<dataflow>
+<info-list>
+<node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>GraphSwitchCheckDefault1</node-name>
+ <kind>1</kind>
+ <coupled-node>?</coupled-node>
+ <service>
+<service-name>GraphSwitchCheckDefault</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>InitLoopSwitch__Index</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>InitLoopSwitch__Min</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>InitLoopSwitch__Max</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>EndOfInitLoopSwitch__Index</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>EndOfInitLoopSwitch__Min</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>EndOfInitLoopSwitch__Max</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list/>
+ <creation-date>13/1/2005 - 12:21:43</creation-date>
+ <lastmodification-date>13/1/2005 - 12:28:19</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>JR</author>
+ <container>?</container>
+ <comment>?</comment>
+ <x-position>0</x-position>
+ <y-position>0</y-position> </node> </info-list>
+ <node-list>
+<node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>IsOdd</node-name>
+ <kind>3</kind>
+ <coupled-node>?</coupled-node>
+ <service>
+<service-name>IsOdd</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>a</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>a</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>IsOdd</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def IsOdd(a) : ]]></PyFunc>
+ <PyFunc><![CDATA[ print a,"IsOdd (GraphSwitch)" ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep( 1 ) ]]></PyFunc>
+ <PyFunc><![CDATA[ return a ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 12:23:17</creation-date>
+ <lastmodification-date>13/1/2005 - 12:23:17</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Python function</comment>
+ <x-position>415</x-position>
+ <y-position>7</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>IsEven</node-name>
+ <kind>3</kind>
+ <coupled-node>?</coupled-node>
+ <service>
+<service-name>IsEven</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>a</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>a</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>IsEven</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def IsEven(a) : ]]></PyFunc>
+ <PyFunc><![CDATA[ print a,"IsEven (GraphSwitch)" ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep( 1 ) ]]></PyFunc>
+ <PyFunc><![CDATA[ return a ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 12:23:17</creation-date>
+ <lastmodification-date>13/1/2005 - 12:23:17</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>421</x-position>
+ <y-position>438</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>PrintOdd</node-name>
+ <kind>3</kind>
+ <coupled-node>?</coupled-node>
+ <service>
+<service-name>PrintOdd</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>a</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>string</inParameter-type>
+ <inParameter-name>Branch</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>string</outParameter-type>
+ <outParameter-name>Branch</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>Print</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def Print(a,Branch) : ]]></PyFunc>
+ <PyFunc><![CDATA[ print "Print ",a,Branch ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep(1) ]]></PyFunc>
+ <PyFunc><![CDATA[ return Branch ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 12:23:17</creation-date>
+ <lastmodification-date>13/1/2005 - 12:23:17</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>415</x-position>
+ <y-position>130</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>PrintEven</node-name>
+ <kind>3</kind>
+ <coupled-node>?</coupled-node>
+ <service>
+<service-name>PrintEven</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>a</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>string</inParameter-type>
+ <inParameter-name>Branch</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>string</outParameter-type>
+ <outParameter-name>Branch</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>Print_1</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def Print_1(a,Branch) : ]]></PyFunc>
+ <PyFunc><![CDATA[ print "Print ",a,Branch ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep(1) ]]></PyFunc>
+ <PyFunc><![CDATA[ return Branch ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 12:23:17</creation-date>
+ <lastmodification-date>13/1/2005 - 12:23:17</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>423</x-position>
+ <y-position>289</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>EmptyNode</node-name>
+ <kind>3</kind>
+ <coupled-node>?</coupled-node>
+ <service>
+<service-name>EmptyNode</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>a</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>string</inParameter-type>
+ <inParameter-name>Branch</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>a</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>string</outParameter-type>
+ <outParameter-name>Branch</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>EmptyNode</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def EmptyNode(a,Branch) : ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep(1) ]]></PyFunc>
+ <PyFunc><![CDATA[ return a,Branch ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 12:23:17</creation-date>
+ <lastmodification-date>13/1/2005 - 12:23:17</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>652</x-position>
+ <y-position>110</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>Default</node-name>
+ <kind>3</kind>
+ <coupled-node>?</coupled-node>
+ <service>
+<service-name>Default</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>a</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>string</inParameter-type>
+ <inParameter-name>Branch</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>a</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>string</outParameter-type>
+ <outParameter-name>Branch</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>Default</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def Default(a,Branch) : ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep(1) ]]></PyFunc>
+ <PyFunc><![CDATA[ return a,Branch ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 12:23:17</creation-date>
+ <lastmodification-date>13/1/2005 - 12:23:17</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>421</x-position>
+ <y-position>592</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>InitLoopSwitch</node-name>
+ <kind>4</kind>
+ <coupled-node>EndOfInitLoopSwitch</coupled-node>
+ <service>
+<service-name>InitLoopSwitch</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>Index</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>Min</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>Max</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>Index</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>Min</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>Max</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>InitLoop</FuncName>
+ <PyFunc><![CDATA[def InitLoop(Index,Min,Max) : ]]></PyFunc>
+ <PyFunc><![CDATA[ Index = Max ]]></PyFunc>
+ <PyFunc><![CDATA[ return Index,Min,Max ]]></PyFunc> </PyFunction>
+ <PyFunction>
+<FuncName>MoreLoop</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def MoreLoop(Index,Min,Max) : ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep(1) ]]></PyFunc>
+ <PyFunc><![CDATA[ if Index >= Min : ]]></PyFunc>
+ <PyFunc><![CDATA[ DoLoop = 1 ]]></PyFunc>
+ <PyFunc><![CDATA[ else : ]]></PyFunc>
+ <PyFunc><![CDATA[ DoLoop = 0 ]]></PyFunc>
+ <PyFunc><![CDATA[ return DoLoop,Index,Min,Max ]]></PyFunc> </PyFunction>
+ <PyFunction>
+<FuncName>NextLoop</FuncName>
+ <PyFunc><![CDATA[def NextLoop(Index,Min,Max) : ]]></PyFunc>
+ <PyFunc><![CDATA[ Index = Index - 1 ]]></PyFunc>
+ <PyFunc><![CDATA[ return Index,Min,Max ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 12:23:17</creation-date>
+ <lastmodification-date>13/1/2005 - 12:23:17</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>10</x-position>
+ <y-position>129</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>EndOfInitLoopSwitch</node-name>
+ <kind>5</kind>
+ <coupled-node>InitLoopSwitch</coupled-node>
+ <service>
+<service-name>EndOfInitLoopSwitch</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>Index</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>Min</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>Max</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>Index</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>Min</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>Max</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>EndOfInitLoopSwitch</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def EndOfInitLoopSwitch(DoLoop,Index,Min,Max) : ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep(1) ]]></PyFunc>
+ <PyFunc><![CDATA[ return DoLoop,Index,Min,Max ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 12:23:17</creation-date>
+ <lastmodification-date>13/1/2005 - 12:23:17</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>1074</x-position>
+ <y-position>194</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>Switch</node-name>
+ <kind>6</kind>
+ <coupled-node>EndOfSwitch</coupled-node>
+ <service>
+<service-name>Switch</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>a</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>Odd</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>int</outParameter-type>
+ <outParameter-name>Even</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>int</outParameter-type>
+ <outParameter-name>a</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>string</outParameter-type>
+ <outParameter-name>Branch</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>boolean</outParameter-type>
+ <outParameter-name>default</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>Switch</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def Switch(a) : ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep(1) ]]></PyFunc>
+ <PyFunc><![CDATA[ Branch = "Negative or null" ]]></PyFunc>
+ <PyFunc><![CDATA[ if a <= 0 : ]]></PyFunc>
+ <PyFunc><![CDATA[ return 0,0,a,Branch,1 ]]></PyFunc>
+ <PyFunc><![CDATA[ if ( a & 1 ) == 0 : ]]></PyFunc>
+ <PyFunc><![CDATA[ Branch = "Even" ]]></PyFunc>
+ <PyFunc><![CDATA[ else : ]]></PyFunc>
+ <PyFunc><![CDATA[ Branch = "Odd" ]]></PyFunc>
+ <PyFunc><![CDATA[ return a & 1,1-(a&1),a,Branch,0 ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 12:23:17</creation-date>
+ <lastmodification-date>13/1/2005 - 12:23:17</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>190</x-position>
+ <y-position>129</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>EndOfSwitch</node-name>
+ <kind>7</kind>
+ <coupled-node>Switch</coupled-node>
+ <service>
+<service-name>EndOfSwitch</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>a</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>string</inParameter-type>
+ <inParameter-name>Branch</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>a</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>EndOfSwitch</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def EndOfSwitch(a,Branch) : ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep(1) ]]></PyFunc>
+ <PyFunc><![CDATA[ return a ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 12:23:17</creation-date>
+ <lastmodification-date>13/1/2005 - 12:23:17</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>882</x-position>
+ <y-position>194</y-position> </node> </node-list>
+ <link-list>
+<link>
+<fromnode-name>IsOdd</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>EmptyNode</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>646</x>
+ <y>78</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>IsEven</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>EndOfSwitch</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>PrintOdd</fromnode-name>
+ <fromserviceparameter-name>Branch</fromserviceparameter-name>
+ <tonode-name>EmptyNode</tonode-name>
+ <toserviceparameter-name>Branch</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>PrintEven</fromnode-name>
+ <fromserviceparameter-name>Branch</fromserviceparameter-name>
+ <tonode-name>EndOfSwitch</tonode-name>
+ <toserviceparameter-name>Branch</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>EmptyNode</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>EndOfSwitch</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>EmptyNode</fromnode-name>
+ <fromserviceparameter-name>Branch</fromserviceparameter-name>
+ <tonode-name>EndOfSwitch</tonode-name>
+ <toserviceparameter-name>Branch</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>Default</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>EndOfSwitch</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>Default</fromnode-name>
+ <fromserviceparameter-name>Branch</fromserviceparameter-name>
+ <tonode-name>EndOfSwitch</tonode-name>
+ <toserviceparameter-name>Branch</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>InitLoopSwitch</fromnode-name>
+ <fromserviceparameter-name>DoLoop</fromserviceparameter-name>
+ <tonode-name>EndOfInitLoopSwitch</tonode-name>
+ <toserviceparameter-name>DoLoop</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>InitLoopSwitch</fromnode-name>
+ <fromserviceparameter-name>Index</fromserviceparameter-name>
+ <tonode-name>Switch</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>InitLoopSwitch</fromnode-name>
+ <fromserviceparameter-name>Min</fromserviceparameter-name>
+ <tonode-name>EndOfInitLoopSwitch</tonode-name>
+ <toserviceparameter-name>Min</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>InitLoopSwitch</fromnode-name>
+ <fromserviceparameter-name>Max</fromserviceparameter-name>
+ <tonode-name>EndOfInitLoopSwitch</tonode-name>
+ <toserviceparameter-name>Max</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>EndOfInitLoopSwitch</fromnode-name>
+ <fromserviceparameter-name>DoLoop</fromserviceparameter-name>
+ <tonode-name>InitLoopSwitch</tonode-name>
+ <toserviceparameter-name>DoLoop</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>Odd</fromserviceparameter-name>
+ <tonode-name>IsOdd</tonode-name>
+ <toserviceparameter-name>Gate</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>401</x>
+ <y>101</y> </coord>
+ <coord>
+<x>401</x>
+ <y>160</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>Odd</fromserviceparameter-name>
+ <tonode-name>PrintOdd</tonode-name>
+ <toserviceparameter-name>Gate</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>401</x>
+ <y>245</y> </coord>
+ <coord>
+<x>401</x>
+ <y>159</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>Even</fromserviceparameter-name>
+ <tonode-name>IsEven</tonode-name>
+ <toserviceparameter-name>Gate</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>392</x>
+ <y>533</y> </coord>
+ <coord>
+<x>392</x>
+ <y>182</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>Even</fromserviceparameter-name>
+ <tonode-name>PrintEven</tonode-name>
+ <toserviceparameter-name>Gate</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>392</x>
+ <y>403</y> </coord>
+ <coord>
+<x>392</x>
+ <y>181</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>IsOdd</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>382</x>
+ <y>78</y> </coord>
+ <coord>
+<x>382</x>
+ <y>199</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>IsEven</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>381</x>
+ <y>509</y> </coord>
+ <coord>
+<x>382</x>
+ <y>200</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>PrintOdd</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>PrintEven</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>381</x>
+ <y>361</y> </coord>
+ <coord>
+<x>382</x>
+ <y>200</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>Default</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>382</x>
+ <y>663</y> </coord>
+ <coord>
+<x>382</x>
+ <y>199</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>Branch</fromserviceparameter-name>
+ <tonode-name>PrintOdd</tonode-name>
+ <toserviceparameter-name>Branch</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>Branch</fromserviceparameter-name>
+ <tonode-name>PrintEven</tonode-name>
+ <toserviceparameter-name>Branch</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>369</x>
+ <y>381</y> </coord>
+ <coord>
+<x>369</x>
+ <y>219</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>Branch</fromserviceparameter-name>
+ <tonode-name>Default</tonode-name>
+ <toserviceparameter-name>Branch</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>370</x>
+ <y>683</y> </coord>
+ <coord>
+<x>370</x>
+ <y>220</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>default</fromserviceparameter-name>
+ <tonode-name>Default</tonode-name>
+ <toserviceparameter-name>Gate</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>363</x>
+ <y>707</y> </coord>
+ <coord>
+<x>362</x>
+ <y>239</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>EndOfSwitch</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>EndOfInitLoopSwitch</tonode-name>
+ <toserviceparameter-name>Index</toserviceparameter-name>
+ <coord-list/> </link> </link-list>
+ <data-list>
+<data>
+<fromnode-name>GraphSwitchCheckDefault1</fromnode-name>
+ <fromserviceparameter-name>InitLoopSwitch__Index</fromserviceparameter-name>
+ <tonode-name>InitLoopSwitch</tonode-name>
+ <toserviceparameter-name>Index</toserviceparameter-name>
+ <data-value>
+<value-type>3</value-type>
+ <value>0</value> </data-value>
+ <coord-list/> </data>
+ <data>
+<fromnode-name>GraphSwitchCheckDefault1</fromnode-name>
+ <fromserviceparameter-name>InitLoopSwitch__Min</fromserviceparameter-name>
+ <tonode-name>InitLoopSwitch</tonode-name>
+ <toserviceparameter-name>Min</toserviceparameter-name>
+ <data-value>
+<value-type>3</value-type>
+ <value>-5</value> </data-value>
+ <coord-list/> </data>
+ <data>
+<fromnode-name>GraphSwitchCheckDefault1</fromnode-name>
+ <fromserviceparameter-name>InitLoopSwitch__Max</fromserviceparameter-name>
+ <tonode-name>InitLoopSwitch</tonode-name>
+ <toserviceparameter-name>Max</toserviceparameter-name>
+ <data-value>
+<value-type>3</value-type>
+ <value>10</value> </data-value>
+ <coord-list/> </data> </data-list> </dataflow></supergraph>
--- /dev/null
+
+# Generated python file of Graph GraphSwitchCheckDefault1
+
+from SuperV import *
+
+# Graph creation of GraphSwitchCheckDefault1
+def DefGraphSwitchCheckDefault1() :
+ GraphSwitchCheckDefault1 = Graph( 'GraphSwitchCheckDefault1' )
+ GraphSwitchCheckDefault1.SetName( 'GraphSwitchCheckDefault1' )
+ GraphSwitchCheckDefault1.SetAuthor( 'JR' )
+ GraphSwitchCheckDefault1.SetComment( '' )
+ GraphSwitchCheckDefault1.Coords( 0 , 0 )
+
+ # Creation of Factory Nodes
+
+ # Creation of InLine Nodes
+ PyIsOdd = []
+ PyIsOdd.append( 'from time import * ' )
+ PyIsOdd.append( 'def IsOdd(a) : ' )
+ PyIsOdd.append( ' print a,"IsOdd (GraphSwitch)" ' )
+ PyIsOdd.append( ' sleep( 1 ) ' )
+ PyIsOdd.append( ' return a ' )
+ IsOdd = GraphSwitchCheckDefault1.INode( 'IsOdd' , PyIsOdd )
+ IsOdd.SetName( 'IsOdd' )
+ IsOdd.SetAuthor( '' )
+ IsOdd.SetComment( 'Python function' )
+ IsOdd.Coords( 415 , 7 )
+ IIsOdda = IsOdd.InPort( 'a' , 'long' )
+ IIsOddGate = IsOdd.GetInPort( 'Gate' )
+ OIsOdda = IsOdd.OutPort( 'a' , 'long' )
+ OIsOddGate = IsOdd.GetOutPort( 'Gate' )
+
+ PyIsEven = []
+ PyIsEven.append( 'from time import * ' )
+ PyIsEven.append( 'def IsEven(a) : ' )
+ PyIsEven.append( ' print a,"IsEven (GraphSwitch)" ' )
+ PyIsEven.append( ' sleep( 1 ) ' )
+ PyIsEven.append( ' return a ' )
+ IsEven = GraphSwitchCheckDefault1.INode( 'IsEven' , PyIsEven )
+ IsEven.SetName( 'IsEven' )
+ IsEven.SetAuthor( '' )
+ IsEven.SetComment( 'Compute Node' )
+ IsEven.Coords( 421 , 438 )
+ IIsEvena = IsEven.InPort( 'a' , 'long' )
+ IIsEvenGate = IsEven.GetInPort( 'Gate' )
+ OIsEvena = IsEven.OutPort( 'a' , 'long' )
+ OIsEvenGate = IsEven.GetOutPort( 'Gate' )
+
+ PyPrintOdd = []
+ PyPrintOdd.append( 'from time import * ' )
+ PyPrintOdd.append( 'def Print(a,Branch) : ' )
+ PyPrintOdd.append( ' print "Print ",a,Branch ' )
+ PyPrintOdd.append( ' sleep(1) ' )
+ PyPrintOdd.append( ' return Branch ' )
+ PrintOdd = GraphSwitchCheckDefault1.INode( 'Print' , PyPrintOdd )
+ PrintOdd.SetName( 'PrintOdd' )
+ PrintOdd.SetAuthor( '' )
+ PrintOdd.SetComment( 'Compute Node' )
+ PrintOdd.Coords( 415 , 130 )
+ IPrintOdda = PrintOdd.InPort( 'a' , 'long' )
+ IPrintOddBranch = PrintOdd.InPort( 'Branch' , 'string' )
+ IPrintOddGate = PrintOdd.GetInPort( 'Gate' )
+ OPrintOddBranch = PrintOdd.OutPort( 'Branch' , 'string' )
+ OPrintOddGate = PrintOdd.GetOutPort( 'Gate' )
+
+ PyPrintEven = []
+ PyPrintEven.append( 'from time import * ' )
+ PyPrintEven.append( 'def Print_1(a,Branch) : ' )
+ PyPrintEven.append( ' print "Print ",a,Branch ' )
+ PyPrintEven.append( ' sleep(1) ' )
+ PyPrintEven.append( ' return Branch ' )
+ PrintEven = GraphSwitchCheckDefault1.INode( 'Print_1' , PyPrintEven )
+ PrintEven.SetName( 'PrintEven' )
+ PrintEven.SetAuthor( '' )
+ PrintEven.SetComment( 'Compute Node' )
+ PrintEven.Coords( 423 , 289 )
+ IPrintEvena = PrintEven.InPort( 'a' , 'long' )
+ IPrintEvenBranch = PrintEven.InPort( 'Branch' , 'string' )
+ IPrintEvenGate = PrintEven.GetInPort( 'Gate' )
+ OPrintEvenBranch = PrintEven.OutPort( 'Branch' , 'string' )
+ OPrintEvenGate = PrintEven.GetOutPort( 'Gate' )
+
+ PyEmptyNode = []
+ PyEmptyNode.append( 'from time import * ' )
+ PyEmptyNode.append( 'def EmptyNode(a,Branch) : ' )
+ PyEmptyNode.append( ' sleep(1) ' )
+ PyEmptyNode.append( ' return a,Branch ' )
+ EmptyNode = GraphSwitchCheckDefault1.INode( 'EmptyNode' , PyEmptyNode )
+ EmptyNode.SetName( 'EmptyNode' )
+ EmptyNode.SetAuthor( '' )
+ EmptyNode.SetComment( 'Compute Node' )
+ EmptyNode.Coords( 652 , 110 )
+ IEmptyNodea = EmptyNode.InPort( 'a' , 'long' )
+ IEmptyNodeBranch = EmptyNode.InPort( 'Branch' , 'string' )
+ IEmptyNodeGate = EmptyNode.GetInPort( 'Gate' )
+ OEmptyNodea = EmptyNode.OutPort( 'a' , 'long' )
+ OEmptyNodeBranch = EmptyNode.OutPort( 'Branch' , 'string' )
+ OEmptyNodeGate = EmptyNode.GetOutPort( 'Gate' )
+
+ PyDefault = []
+ PyDefault.append( 'from time import * ' )
+ PyDefault.append( 'def Default(a,Branch) : ' )
+ PyDefault.append( ' sleep(1) ' )
+ PyDefault.append( ' return a,Branch ' )
+ Default = GraphSwitchCheckDefault1.INode( 'Default' , PyDefault )
+ Default.SetName( 'Default' )
+ Default.SetAuthor( '' )
+ Default.SetComment( 'Compute Node' )
+ Default.Coords( 421 , 592 )
+ IDefaulta = Default.InPort( 'a' , 'long' )
+ IDefaultBranch = Default.InPort( 'Branch' , 'string' )
+ IDefaultGate = Default.GetInPort( 'Gate' )
+ ODefaulta = Default.OutPort( 'a' , 'long' )
+ ODefaultBranch = Default.OutPort( 'Branch' , 'string' )
+ ODefaultGate = Default.GetOutPort( 'Gate' )
+
+ PyPuta = []
+ PyPuta.append( 'from time import * ' )
+ PyPuta.append( 'def Puta(a) : ' )
+ PyPuta.append( ' sleep(1) ' )
+ PyPuta.append( ' return a ' )
+ Puta = GraphSwitchCheckDefault1.INode( 'Puta' , PyPuta )
+ Puta.SetName( 'Puta' )
+ Puta.SetAuthor( '' )
+ Puta.SetComment( 'Compute Node' )
+ Puta.Coords( 658 , 472 )
+ IPutaa = Puta.InPort( 'a' , 'long' )
+ IPutaGate = Puta.GetInPort( 'Gate' )
+ OPutaa = Puta.OutPort( 'a' , 'long' )
+ OPutaGate = Puta.GetOutPort( 'Gate' )
+
+ PyPutBranch = []
+ PyPutBranch.append( 'from time import * ' )
+ PyPutBranch.append( 'def PutBranch(Branch) : ' )
+ PyPutBranch.append( ' sleep(1) ' )
+ PyPutBranch.append( ' return Branch ' )
+ PutBranch = GraphSwitchCheckDefault1.INode( 'PutBranch' , PyPutBranch )
+ PutBranch.SetName( 'PutBranch' )
+ PutBranch.SetAuthor( '' )
+ PutBranch.SetComment( 'Compute Node' )
+ PutBranch.Coords( 662 , 613 )
+ IPutBranchBranch = PutBranch.InPort( 'Branch' , 'string' )
+ IPutBranchGate = PutBranch.GetInPort( 'Gate' )
+ OPutBranchBranch = PutBranch.OutPort( 'Branch' , 'string' )
+ OPutBranchGate = PutBranch.GetOutPort( 'Gate' )
+
+ # Creation of Loop Nodes
+ PyInitLoopSwitch = []
+ PyInitLoopSwitch.append( 'def InitLoop(Index,Min,Max) : ' )
+ PyInitLoopSwitch.append( ' Index = Max ' )
+ PyInitLoopSwitch.append( ' return Index,Min,Max ' )
+ PyMoreInitLoopSwitch = []
+ PyMoreInitLoopSwitch.append( 'from time import * ' )
+ PyMoreInitLoopSwitch.append( 'def MoreLoop(Index,Min,Max) : ' )
+ PyMoreInitLoopSwitch.append( ' sleep(1) ' )
+ PyMoreInitLoopSwitch.append( ' if Index >= Min : ' )
+ PyMoreInitLoopSwitch.append( ' DoLoop = 1 ' )
+ PyMoreInitLoopSwitch.append( ' else : ' )
+ PyMoreInitLoopSwitch.append( ' DoLoop = 0 ' )
+ PyMoreInitLoopSwitch.append( ' return DoLoop,Index,Min,Max ' )
+ PyNextInitLoopSwitch = []
+ PyNextInitLoopSwitch.append( 'def NextLoop(Index,Min,Max) : ' )
+ PyNextInitLoopSwitch.append( ' Index = Index - 1 ' )
+ PyNextInitLoopSwitch.append( ' return Index,Min,Max ' )
+ InitLoopSwitch,EndOfInitLoopSwitch = GraphSwitchCheckDefault1.LNode( 'InitLoop' , PyInitLoopSwitch , 'MoreLoop' , PyMoreInitLoopSwitch , 'NextLoop' , PyNextInitLoopSwitch )
+ EndOfInitLoopSwitch.SetName( 'EndOfInitLoopSwitch' )
+ EndOfInitLoopSwitch.SetAuthor( '' )
+ EndOfInitLoopSwitch.SetComment( 'Compute Node' )
+ EndOfInitLoopSwitch.Coords( 1074 , 194 )
+ PyEndOfInitLoopSwitch = []
+ PyEndOfInitLoopSwitch.append( 'from time import * ' )
+ PyEndOfInitLoopSwitch.append( 'def EndOfInitLoopSwitch(DoLoop,Index,Min,Max) : ' )
+ PyEndOfInitLoopSwitch.append( ' sleep(1) ' )
+ PyEndOfInitLoopSwitch.append( ' return DoLoop,Index,Min,Max ' )
+ EndOfInitLoopSwitch.SetPyFunction( 'EndOfInitLoopSwitch' , PyEndOfInitLoopSwitch )
+ IInitLoopSwitchDoLoop = InitLoopSwitch.GetInPort( 'DoLoop' )
+ IInitLoopSwitchIndex = InitLoopSwitch.InPort( 'Index' , 'long' )
+ IInitLoopSwitchMin = InitLoopSwitch.InPort( 'Min' , 'long' )
+ IInitLoopSwitchMax = InitLoopSwitch.InPort( 'Max' , 'long' )
+ IInitLoopSwitchGate = InitLoopSwitch.GetInPort( 'Gate' )
+ OInitLoopSwitchDoLoop = InitLoopSwitch.GetOutPort( 'DoLoop' )
+ OInitLoopSwitchIndex = InitLoopSwitch.GetOutPort( 'Index' )
+ OInitLoopSwitchMin = InitLoopSwitch.GetOutPort( 'Min' )
+ OInitLoopSwitchMax = InitLoopSwitch.GetOutPort( 'Max' )
+ IEndOfInitLoopSwitchDoLoop = EndOfInitLoopSwitch.GetInPort( 'DoLoop' )
+ IEndOfInitLoopSwitchIndex = EndOfInitLoopSwitch.GetInPort( 'Index' )
+ IEndOfInitLoopSwitchMin = EndOfInitLoopSwitch.GetInPort( 'Min' )
+ IEndOfInitLoopSwitchMax = EndOfInitLoopSwitch.GetInPort( 'Max' )
+ IEndOfInitLoopSwitchGate = EndOfInitLoopSwitch.GetInPort( 'Gate' )
+ OEndOfInitLoopSwitchDoLoop = EndOfInitLoopSwitch.GetOutPort( 'DoLoop' )
+ OEndOfInitLoopSwitchIndex = EndOfInitLoopSwitch.GetOutPort( 'Index' )
+ OEndOfInitLoopSwitchMin = EndOfInitLoopSwitch.GetOutPort( 'Min' )
+ OEndOfInitLoopSwitchMax = EndOfInitLoopSwitch.GetOutPort( 'Max' )
+ OEndOfInitLoopSwitchGate = EndOfInitLoopSwitch.GetOutPort( 'Gate' )
+ InitLoopSwitch.SetName( 'InitLoopSwitch' )
+ InitLoopSwitch.SetAuthor( '' )
+ InitLoopSwitch.SetComment( 'Compute Node' )
+ InitLoopSwitch.Coords( 10 , 129 )
+
+ # Creation of Switch Nodes
+ PySwitch = []
+ PySwitch.append( 'from time import * ' )
+ PySwitch.append( 'def Switch(a) : ' )
+ PySwitch.append( ' sleep(1) ' )
+ PySwitch.append( ' Branch = "Negative or null" ' )
+ PySwitch.append( ' if a <= 0 : ' )
+ PySwitch.append( ' return 0,0,a,Branch,1 ' )
+ PySwitch.append( ' if ( a & 1 ) == 0 : ' )
+ PySwitch.append( ' Branch = "Even" ' )
+ PySwitch.append( ' else : ' )
+ PySwitch.append( ' Branch = "Odd" ' )
+ PySwitch.append( ' return a & 1,1-(a&1),a,Branch,0 ' )
+ Switch,EndOfSwitch = GraphSwitchCheckDefault1.SNode( 'Switch' , PySwitch )
+ EndOfSwitch.SetName( 'EndOfSwitch' )
+ EndOfSwitch.SetAuthor( '' )
+ EndOfSwitch.SetComment( 'Compute Node' )
+ EndOfSwitch.Coords( 882 , 194 )
+ PyEndOfSwitch = []
+ PyEndOfSwitch.append( 'from time import * ' )
+ PyEndOfSwitch.append( 'def EndOfSwitch(a,Branch) : ' )
+ PyEndOfSwitch.append( ' sleep(1) ' )
+ PyEndOfSwitch.append( ' return a ' )
+ EndOfSwitch.SetPyFunction( 'EndOfSwitch' , PyEndOfSwitch )
+ IEndOfSwitcha = EndOfSwitch.InPort( 'a' , 'long' )
+ IEndOfSwitchBranch = EndOfSwitch.InPort( 'Branch' , 'string' )
+ IEndOfSwitchDefault = EndOfSwitch.GetInPort( 'Default' )
+ OEndOfSwitcha = EndOfSwitch.OutPort( 'a' , 'long' )
+ OEndOfSwitchGate = EndOfSwitch.GetOutPort( 'Gate' )
+ Switch.SetName( 'Switch' )
+ Switch.SetAuthor( '' )
+ Switch.SetComment( 'Compute Node' )
+ Switch.Coords( 190 , 129 )
+ ISwitcha = Switch.InPort( 'a' , 'long' )
+ ISwitchGate = Switch.GetInPort( 'Gate' )
+ OSwitchOdd = Switch.OutPort( 'Odd' , 'long' )
+ OSwitchEven = Switch.OutPort( 'Even' , 'int' )
+ OSwitcha = Switch.OutPort( 'a' , 'int' )
+ OSwitchBranch = Switch.OutPort( 'Branch' , 'string' )
+ OSwitchdefault = Switch.OutPort( 'default' , 'boolean' )
+ OSwitchDefault = Switch.GetOutPort( 'Default' )
+
+ # Creation of Links
+ LIsOddaEmptyNodea = GraphSwitchCheckDefault1.Link( OIsOdda , IEmptyNodea )
+ LIsOddaEmptyNodea.AddCoord( 1 , 646 , 78 )
+
+ LPrintOddBranchEmptyNodeBranch = GraphSwitchCheckDefault1.Link( OPrintOddBranch , IEmptyNodeBranch )
+
+ LEmptyNodeaEndOfSwitcha = GraphSwitchCheckDefault1.Link( OEmptyNodea , IEndOfSwitcha )
+
+ LEmptyNodeBranchEndOfSwitchBranch = GraphSwitchCheckDefault1.Link( OEmptyNodeBranch , IEndOfSwitchBranch )
+
+ LDefaultaEndOfSwitcha = GraphSwitchCheckDefault1.Link( ODefaulta , IEndOfSwitcha )
+
+ LDefaultaPutaa = GraphSwitchCheckDefault1.Link( ODefaulta , IPutaa )
+
+ LDefaultBranchEndOfSwitchBranch = GraphSwitchCheckDefault1.Link( ODefaultBranch , IEndOfSwitchBranch )
+
+ LDefaultBranchPutBranchBranch = GraphSwitchCheckDefault1.Link( ODefaultBranch , IPutBranchBranch )
+
+ LInitLoopSwitchIndexSwitcha = GraphSwitchCheckDefault1.Link( OInitLoopSwitchIndex , ISwitcha )
+
+ LInitLoopSwitchMinEndOfInitLoopSwitchMin = GraphSwitchCheckDefault1.Link( OInitLoopSwitchMin , IEndOfInitLoopSwitchMin )
+
+ LInitLoopSwitchMaxEndOfInitLoopSwitchMax = GraphSwitchCheckDefault1.Link( OInitLoopSwitchMax , IEndOfInitLoopSwitchMax )
+
+ LSwitchOddIsOddGate = GraphSwitchCheckDefault1.Link( OSwitchOdd , IIsOddGate )
+ LSwitchOddIsOddGate.AddCoord( 1 , 401 , 101 )
+ LSwitchOddIsOddGate.AddCoord( 2 , 401 , 160 )
+
+ LSwitchOddPrintOddGate = GraphSwitchCheckDefault1.Link( OSwitchOdd , IPrintOddGate )
+ LSwitchOddPrintOddGate.AddCoord( 1 , 401 , 245 )
+ LSwitchOddPrintOddGate.AddCoord( 2 , 401 , 159 )
+
+ LSwitchEvenIsEvenGate = GraphSwitchCheckDefault1.Link( OSwitchEven , IIsEvenGate )
+ LSwitchEvenIsEvenGate.AddCoord( 1 , 392 , 533 )
+ LSwitchEvenIsEvenGate.AddCoord( 2 , 392 , 182 )
+
+ LSwitchEvenPrintEvenGate = GraphSwitchCheckDefault1.Link( OSwitchEven , IPrintEvenGate )
+ LSwitchEvenPrintEvenGate.AddCoord( 1 , 392 , 403 )
+ LSwitchEvenPrintEvenGate.AddCoord( 2 , 392 , 181 )
+
+ LSwitchaIsOdda = GraphSwitchCheckDefault1.Link( OSwitcha , IIsOdda )
+ LSwitchaIsOdda.AddCoord( 1 , 382 , 78 )
+ LSwitchaIsOdda.AddCoord( 2 , 382 , 199 )
+
+ LSwitchaIsEvena = GraphSwitchCheckDefault1.Link( OSwitcha , IIsEvena )
+ LSwitchaIsEvena.AddCoord( 1 , 381 , 509 )
+ LSwitchaIsEvena.AddCoord( 2 , 382 , 200 )
+
+ LSwitchaPrintOdda = GraphSwitchCheckDefault1.Link( OSwitcha , IPrintOdda )
+
+ LSwitchaPrintEvena = GraphSwitchCheckDefault1.Link( OSwitcha , IPrintEvena )
+ LSwitchaPrintEvena.AddCoord( 1 , 381 , 361 )
+ LSwitchaPrintEvena.AddCoord( 2 , 382 , 200 )
+
+ LSwitchaDefaulta = GraphSwitchCheckDefault1.Link( OSwitcha , IDefaulta )
+ LSwitchaDefaulta.AddCoord( 1 , 382 , 663 )
+ LSwitchaDefaulta.AddCoord( 2 , 382 , 199 )
+
+ LSwitchBranchPrintOddBranch = GraphSwitchCheckDefault1.Link( OSwitchBranch , IPrintOddBranch )
+
+ LSwitchBranchPrintEvenBranch = GraphSwitchCheckDefault1.Link( OSwitchBranch , IPrintEvenBranch )
+ LSwitchBranchPrintEvenBranch.AddCoord( 1 , 369 , 381 )
+ LSwitchBranchPrintEvenBranch.AddCoord( 2 , 369 , 219 )
+
+ LSwitchBranchDefaultBranch = GraphSwitchCheckDefault1.Link( OSwitchBranch , IDefaultBranch )
+ LSwitchBranchDefaultBranch.AddCoord( 1 , 370 , 683 )
+ LSwitchBranchDefaultBranch.AddCoord( 2 , 370 , 220 )
+
+ LSwitchdefaultDefaultGate = GraphSwitchCheckDefault1.Link( OSwitchdefault , IDefaultGate )
+ LSwitchdefaultDefaultGate.AddCoord( 1 , 363 , 707 )
+ LSwitchdefaultDefaultGate.AddCoord( 2 , 362 , 239 )
+
+ LEndOfSwitchaEndOfInitLoopSwitchIndex = GraphSwitchCheckDefault1.Link( OEndOfSwitcha , IEndOfInitLoopSwitchIndex )
+
+ LPutaaEndOfSwitcha = GraphSwitchCheckDefault1.Link( OPutaa , IEndOfSwitcha )
+
+ LPutBranchBranchEndOfSwitchBranch = GraphSwitchCheckDefault1.Link( OPutBranchBranch , IEndOfSwitchBranch )
+
+ # Input datas
+ IInitLoopSwitchIndex.Input( 0 )
+ IInitLoopSwitchMin.Input( -5 )
+ IInitLoopSwitchMax.Input( 10 )
+
+ # Output Ports of the graph
+ #OIsEvena = IsEven.GetOutPort( 'a' )
+ #OPrintEvenBranch = PrintEven.GetOutPort( 'Branch' )
+ #OEndOfInitLoopSwitchIndex = EndOfInitLoopSwitch.GetOutPort( 'Index' )
+ #OEndOfInitLoopSwitchMin = EndOfInitLoopSwitch.GetOutPort( 'Min' )
+ #OEndOfInitLoopSwitchMax = EndOfInitLoopSwitch.GetOutPort( 'Max' )
+ return GraphSwitchCheckDefault1
+
+
+GraphSwitchCheckDefault1 = DefGraphSwitchCheckDefault1()
--- /dev/null
+<!DOCTYPE SuperGraph>
+<supergraph>
+<dataflow>
+<info-list>
+<node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>GraphSwitchCheckDefault1</node-name>
+ <kind>1</kind>
+ <coupled-node>?</coupled-node>
+ <service>
+<service-name>GraphSwitchCheckDefault1</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>InitLoopSwitch__Index</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>InitLoopSwitch__Min</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>InitLoopSwitch__Max</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>IsEven__a</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>string</outParameter-type>
+ <outParameter-name>PrintEven__Branch</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>EndOfInitLoopSwitch__Index</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>EndOfInitLoopSwitch__Min</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>EndOfInitLoopSwitch__Max</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list/>
+ <creation-date>13/1/2005 - 12:21:43</creation-date>
+ <lastmodification-date>13/1/2005 - 12:33:25</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>JR</author>
+ <container>?</container>
+ <comment>?</comment>
+ <x-position>0</x-position>
+ <y-position>0</y-position> </node> </info-list>
+ <node-list>
+<node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>IsOdd</node-name>
+ <kind>3</kind>
+ <coupled-node>?</coupled-node>
+ <service>
+<service-name>IsOdd</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>a</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>a</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>IsOdd</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def IsOdd(a) : ]]></PyFunc>
+ <PyFunc><![CDATA[ print a,"IsOdd (GraphSwitch)" ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep( 1 ) ]]></PyFunc>
+ <PyFunc><![CDATA[ return a ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 12:23:17</creation-date>
+ <lastmodification-date>13/1/2005 - 12:23:17</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Python function</comment>
+ <x-position>415</x-position>
+ <y-position>7</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>IsEven</node-name>
+ <kind>3</kind>
+ <coupled-node>?</coupled-node>
+ <service>
+<service-name>IsEven</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>a</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>a</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>IsEven</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def IsEven(a) : ]]></PyFunc>
+ <PyFunc><![CDATA[ print a,"IsEven (GraphSwitch)" ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep( 1 ) ]]></PyFunc>
+ <PyFunc><![CDATA[ return a ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 12:23:17</creation-date>
+ <lastmodification-date>13/1/2005 - 12:23:17</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>421</x-position>
+ <y-position>438</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>PrintOdd</node-name>
+ <kind>3</kind>
+ <coupled-node>?</coupled-node>
+ <service>
+<service-name>PrintOdd</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>a</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>string</inParameter-type>
+ <inParameter-name>Branch</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>string</outParameter-type>
+ <outParameter-name>Branch</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>Print</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def Print(a,Branch) : ]]></PyFunc>
+ <PyFunc><![CDATA[ print "Print ",a,Branch ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep(1) ]]></PyFunc>
+ <PyFunc><![CDATA[ return Branch ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 12:23:17</creation-date>
+ <lastmodification-date>13/1/2005 - 12:23:17</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>415</x-position>
+ <y-position>130</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>PrintEven</node-name>
+ <kind>3</kind>
+ <coupled-node>?</coupled-node>
+ <service>
+<service-name>PrintEven</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>a</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>string</inParameter-type>
+ <inParameter-name>Branch</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>string</outParameter-type>
+ <outParameter-name>Branch</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>Print_1</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def Print_1(a,Branch) : ]]></PyFunc>
+ <PyFunc><![CDATA[ print "Print ",a,Branch ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep(1) ]]></PyFunc>
+ <PyFunc><![CDATA[ return Branch ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 12:23:17</creation-date>
+ <lastmodification-date>13/1/2005 - 12:23:17</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>423</x-position>
+ <y-position>289</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>EmptyNode</node-name>
+ <kind>3</kind>
+ <coupled-node>?</coupled-node>
+ <service>
+<service-name>EmptyNode</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>a</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>string</inParameter-type>
+ <inParameter-name>Branch</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>a</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>string</outParameter-type>
+ <outParameter-name>Branch</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>EmptyNode</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def EmptyNode(a,Branch) : ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep(1) ]]></PyFunc>
+ <PyFunc><![CDATA[ return a,Branch ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 12:23:17</creation-date>
+ <lastmodification-date>13/1/2005 - 12:23:17</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>652</x-position>
+ <y-position>110</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>Default</node-name>
+ <kind>3</kind>
+ <coupled-node>?</coupled-node>
+ <service>
+<service-name>Default</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>a</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>string</inParameter-type>
+ <inParameter-name>Branch</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>a</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>string</outParameter-type>
+ <outParameter-name>Branch</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>Default</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def Default(a,Branch) : ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep(1) ]]></PyFunc>
+ <PyFunc><![CDATA[ return a,Branch ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 12:23:17</creation-date>
+ <lastmodification-date>13/1/2005 - 12:23:17</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>421</x-position>
+ <y-position>592</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>InitLoopSwitch</node-name>
+ <kind>4</kind>
+ <coupled-node>EndOfInitLoopSwitch</coupled-node>
+ <service>
+<service-name>InitLoopSwitch</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>Index</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>Min</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>Max</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>Index</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>Min</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>Max</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>InitLoop</FuncName>
+ <PyFunc><![CDATA[def InitLoop(Index,Min,Max) : ]]></PyFunc>
+ <PyFunc><![CDATA[ Index = Max ]]></PyFunc>
+ <PyFunc><![CDATA[ return Index,Min,Max ]]></PyFunc> </PyFunction>
+ <PyFunction>
+<FuncName>MoreLoop</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def MoreLoop(Index,Min,Max) : ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep(1) ]]></PyFunc>
+ <PyFunc><![CDATA[ if Index >= Min : ]]></PyFunc>
+ <PyFunc><![CDATA[ DoLoop = 1 ]]></PyFunc>
+ <PyFunc><![CDATA[ else : ]]></PyFunc>
+ <PyFunc><![CDATA[ DoLoop = 0 ]]></PyFunc>
+ <PyFunc><![CDATA[ return DoLoop,Index,Min,Max ]]></PyFunc> </PyFunction>
+ <PyFunction>
+<FuncName>NextLoop</FuncName>
+ <PyFunc><![CDATA[def NextLoop(Index,Min,Max) : ]]></PyFunc>
+ <PyFunc><![CDATA[ Index = Index - 1 ]]></PyFunc>
+ <PyFunc><![CDATA[ return Index,Min,Max ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 12:23:17</creation-date>
+ <lastmodification-date>13/1/2005 - 12:23:17</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>10</x-position>
+ <y-position>129</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>EndOfInitLoopSwitch</node-name>
+ <kind>5</kind>
+ <coupled-node>InitLoopSwitch</coupled-node>
+ <service>
+<service-name>EndOfInitLoopSwitch</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>Index</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>Min</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>Max</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>Index</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>Min</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>Max</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>EndOfInitLoopSwitch</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def EndOfInitLoopSwitch(DoLoop,Index,Min,Max) : ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep(1) ]]></PyFunc>
+ <PyFunc><![CDATA[ return DoLoop,Index,Min,Max ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 12:23:17</creation-date>
+ <lastmodification-date>13/1/2005 - 12:23:17</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>1074</x-position>
+ <y-position>194</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>Switch</node-name>
+ <kind>6</kind>
+ <coupled-node>EndOfSwitch</coupled-node>
+ <service>
+<service-name>Switch</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>a</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>Odd</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>int</outParameter-type>
+ <outParameter-name>Even</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>int</outParameter-type>
+ <outParameter-name>a</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>string</outParameter-type>
+ <outParameter-name>Branch</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>boolean</outParameter-type>
+ <outParameter-name>default</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>Switch</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def Switch(a) : ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep(1) ]]></PyFunc>
+ <PyFunc><![CDATA[ Branch = "Negative or null" ]]></PyFunc>
+ <PyFunc><![CDATA[ if a <= 0 : ]]></PyFunc>
+ <PyFunc><![CDATA[ return 0,0,a,Branch,1 ]]></PyFunc>
+ <PyFunc><![CDATA[ if ( a & 1 ) == 0 : ]]></PyFunc>
+ <PyFunc><![CDATA[ Branch = "Even" ]]></PyFunc>
+ <PyFunc><![CDATA[ else : ]]></PyFunc>
+ <PyFunc><![CDATA[ Branch = "Odd" ]]></PyFunc>
+ <PyFunc><![CDATA[ return a & 1,1-(a&1),a,Branch,0 ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 12:23:17</creation-date>
+ <lastmodification-date>13/1/2005 - 12:23:17</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>190</x-position>
+ <y-position>129</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>EndOfSwitch</node-name>
+ <kind>7</kind>
+ <coupled-node>Switch</coupled-node>
+ <service>
+<service-name>EndOfSwitch</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>a</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>string</inParameter-type>
+ <inParameter-name>Branch</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>a</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>EndOfSwitch</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def EndOfSwitch(a,Branch) : ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep(1) ]]></PyFunc>
+ <PyFunc><![CDATA[ return a ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 12:23:17</creation-date>
+ <lastmodification-date>13/1/2005 - 12:23:17</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>882</x-position>
+ <y-position>194</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>Puta</node-name>
+ <kind>3</kind>
+ <coupled-node>?</coupled-node>
+ <service>
+<service-name>Puta</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>a</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>a</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>Puta</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def Puta(a) : ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep(1) ]]></PyFunc>
+ <PyFunc><![CDATA[ return a ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 12:31:48</creation-date>
+ <lastmodification-date>13/1/2005 - 12:31:48</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>658</x-position>
+ <y-position>472</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>PutBranch</node-name>
+ <kind>3</kind>
+ <coupled-node>?</coupled-node>
+ <service>
+<service-name>PutBranch</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>string</inParameter-type>
+ <inParameter-name>Branch</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>string</outParameter-type>
+ <outParameter-name>Branch</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>PutBranch</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def PutBranch(Branch) : ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep(1) ]]></PyFunc>
+ <PyFunc><![CDATA[ return Branch ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 12:32:11</creation-date>
+ <lastmodification-date>13/1/2005 - 12:32:11</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>662</x-position>
+ <y-position>613</y-position> </node> </node-list>
+ <link-list>
+<link>
+<fromnode-name>IsOdd</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>EmptyNode</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>646</x>
+ <y>78</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>PrintOdd</fromnode-name>
+ <fromserviceparameter-name>Branch</fromserviceparameter-name>
+ <tonode-name>EmptyNode</tonode-name>
+ <toserviceparameter-name>Branch</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>EmptyNode</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>EndOfSwitch</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>EmptyNode</fromnode-name>
+ <fromserviceparameter-name>Branch</fromserviceparameter-name>
+ <tonode-name>EndOfSwitch</tonode-name>
+ <toserviceparameter-name>Branch</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>Default</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>EndOfSwitch</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>Default</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>Puta</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>Default</fromnode-name>
+ <fromserviceparameter-name>Branch</fromserviceparameter-name>
+ <tonode-name>EndOfSwitch</tonode-name>
+ <toserviceparameter-name>Branch</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>Default</fromnode-name>
+ <fromserviceparameter-name>Branch</fromserviceparameter-name>
+ <tonode-name>PutBranch</tonode-name>
+ <toserviceparameter-name>Branch</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>InitLoopSwitch</fromnode-name>
+ <fromserviceparameter-name>DoLoop</fromserviceparameter-name>
+ <tonode-name>EndOfInitLoopSwitch</tonode-name>
+ <toserviceparameter-name>DoLoop</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>InitLoopSwitch</fromnode-name>
+ <fromserviceparameter-name>Index</fromserviceparameter-name>
+ <tonode-name>Switch</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>InitLoopSwitch</fromnode-name>
+ <fromserviceparameter-name>Min</fromserviceparameter-name>
+ <tonode-name>EndOfInitLoopSwitch</tonode-name>
+ <toserviceparameter-name>Min</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>InitLoopSwitch</fromnode-name>
+ <fromserviceparameter-name>Max</fromserviceparameter-name>
+ <tonode-name>EndOfInitLoopSwitch</tonode-name>
+ <toserviceparameter-name>Max</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>EndOfInitLoopSwitch</fromnode-name>
+ <fromserviceparameter-name>DoLoop</fromserviceparameter-name>
+ <tonode-name>InitLoopSwitch</tonode-name>
+ <toserviceparameter-name>DoLoop</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>Odd</fromserviceparameter-name>
+ <tonode-name>IsOdd</tonode-name>
+ <toserviceparameter-name>Gate</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>401</x>
+ <y>101</y> </coord>
+ <coord>
+<x>401</x>
+ <y>160</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>Odd</fromserviceparameter-name>
+ <tonode-name>PrintOdd</tonode-name>
+ <toserviceparameter-name>Gate</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>401</x>
+ <y>245</y> </coord>
+ <coord>
+<x>401</x>
+ <y>159</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>Even</fromserviceparameter-name>
+ <tonode-name>IsEven</tonode-name>
+ <toserviceparameter-name>Gate</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>392</x>
+ <y>533</y> </coord>
+ <coord>
+<x>392</x>
+ <y>182</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>Even</fromserviceparameter-name>
+ <tonode-name>PrintEven</tonode-name>
+ <toserviceparameter-name>Gate</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>392</x>
+ <y>403</y> </coord>
+ <coord>
+<x>392</x>
+ <y>181</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>IsOdd</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>382</x>
+ <y>78</y> </coord>
+ <coord>
+<x>382</x>
+ <y>199</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>IsEven</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>381</x>
+ <y>509</y> </coord>
+ <coord>
+<x>382</x>
+ <y>200</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>PrintOdd</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>PrintEven</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>381</x>
+ <y>361</y> </coord>
+ <coord>
+<x>382</x>
+ <y>200</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>Default</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>382</x>
+ <y>663</y> </coord>
+ <coord>
+<x>382</x>
+ <y>199</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>Branch</fromserviceparameter-name>
+ <tonode-name>PrintOdd</tonode-name>
+ <toserviceparameter-name>Branch</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>Branch</fromserviceparameter-name>
+ <tonode-name>PrintEven</tonode-name>
+ <toserviceparameter-name>Branch</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>369</x>
+ <y>381</y> </coord>
+ <coord>
+<x>369</x>
+ <y>219</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>Branch</fromserviceparameter-name>
+ <tonode-name>Default</tonode-name>
+ <toserviceparameter-name>Branch</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>370</x>
+ <y>683</y> </coord>
+ <coord>
+<x>370</x>
+ <y>220</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>default</fromserviceparameter-name>
+ <tonode-name>Default</tonode-name>
+ <toserviceparameter-name>Gate</toserviceparameter-name>
+ <coord-list>
+<coord>
+<x>363</x>
+ <y>707</y> </coord>
+ <coord>
+<x>362</x>
+ <y>239</y> </coord> </coord-list> </link>
+ <link>
+<fromnode-name>EndOfSwitch</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>EndOfInitLoopSwitch</tonode-name>
+ <toserviceparameter-name>Index</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>Puta</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>EndOfSwitch</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>PutBranch</fromnode-name>
+ <fromserviceparameter-name>Branch</fromserviceparameter-name>
+ <tonode-name>EndOfSwitch</tonode-name>
+ <toserviceparameter-name>Branch</toserviceparameter-name>
+ <coord-list/> </link> </link-list>
+ <data-list>
+<data>
+<fromnode-name>GraphSwitchCheckDefault1</fromnode-name>
+ <fromserviceparameter-name>InitLoopSwitch__Index</fromserviceparameter-name>
+ <tonode-name>InitLoopSwitch</tonode-name>
+ <toserviceparameter-name>Index</toserviceparameter-name>
+ <data-value>
+<value-type>3</value-type>
+ <value>0</value> </data-value>
+ <coord-list/> </data>
+ <data>
+<fromnode-name>GraphSwitchCheckDefault1</fromnode-name>
+ <fromserviceparameter-name>InitLoopSwitch__Min</fromserviceparameter-name>
+ <tonode-name>InitLoopSwitch</tonode-name>
+ <toserviceparameter-name>Min</toserviceparameter-name>
+ <data-value>
+<value-type>3</value-type>
+ <value>-5</value> </data-value>
+ <coord-list/> </data>
+ <data>
+<fromnode-name>GraphSwitchCheckDefault1</fromnode-name>
+ <fromserviceparameter-name>InitLoopSwitch__Max</fromserviceparameter-name>
+ <tonode-name>InitLoopSwitch</tonode-name>
+ <toserviceparameter-name>Max</toserviceparameter-name>
+ <data-value>
+<value-type>3</value-type>
+ <value>10</value> </data-value>
+ <coord-list/> </data> </data-list> </dataflow></supergraph>
--- /dev/null
+
+# Generated python file of Graph GraphSwitch_1_1
+
+from SuperV import *
+
+# Graph creation of GraphSwitch_1_1
+def DefGraphSwitch_1_1() :
+ GraphSwitch_1_1 = Graph( 'GraphSwitch_1_1' )
+ GraphSwitch_1_1.SetName( 'GraphSwitch_1_1' )
+ GraphSwitch_1_1.SetAuthor( '' )
+ GraphSwitch_1_1.SetComment( '' )
+ GraphSwitch_1_1.Coords( 0 , 0 )
+
+ # Creation of Factory Nodes
+
+ # Creation of InLine Nodes
+ PyIsOdd = []
+ PyIsOdd.append( 'from time import * ' )
+ PyIsOdd.append( 'def IsOdd(a) : ' )
+ PyIsOdd.append( ' print a,"IsOdd (GraphSwitch)" ' )
+ PyIsOdd.append( ' sleep( 1 ) ' )
+ PyIsOdd.append( ' return a ' )
+ IsOdd = GraphSwitch_1_1.INode( 'IsOdd' , PyIsOdd )
+ IsOdd.SetName( 'IsOdd' )
+ IsOdd.SetAuthor( '' )
+ IsOdd.SetComment( 'Python function' )
+ IsOdd.Coords( 388 , 50 )
+ IIsOdda = IsOdd.InPort( 'a' , 'long' )
+ IIsOddGate = IsOdd.GetInPort( 'Gate' )
+ OIsOdda = IsOdd.OutPort( 'a' , 'long' )
+ OIsOddGate = IsOdd.GetOutPort( 'Gate' )
+
+ PyIsEven = []
+ PyIsEven.append( 'from time import * ' )
+ PyIsEven.append( 'def IsEven(a) : ' )
+ PyIsEven.append( ' print a,"IsEven (GraphSwitch)" ' )
+ PyIsEven.append( ' sleep( 1 ) ' )
+ PyIsEven.append( ' return a ' )
+ IsEven = GraphSwitch_1_1.INode( 'IsEven' , PyIsEven )
+ IsEven.SetName( 'IsEven' )
+ IsEven.SetAuthor( '' )
+ IsEven.SetComment( 'Compute Node' )
+ IsEven.Coords( 395 , 334 )
+ IIsEvena = IsEven.InPort( 'a' , 'long' )
+ IIsEvenGate = IsEven.GetInPort( 'Gate' )
+ OIsEvena = IsEven.OutPort( 'a' , 'long' )
+ OIsEvenGate = IsEven.GetOutPort( 'Gate' )
+
+ PyPrint = []
+ PyPrint.append( 'def Print(a,Branch) : ' )
+ PyPrint.append( ' print "Print ",Branch ' )
+ PyPrint.append( ' return a,Branch ' )
+ Print = GraphSwitch_1_1.INode( 'Print' , PyPrint )
+ Print.SetName( 'Print' )
+ Print.SetAuthor( '' )
+ Print.SetComment( 'Compute Node' )
+ Print.Coords( 639 , 63 )
+ IPrinta = Print.InPort( 'a' , 'long' )
+ IPrintBranch = Print.InPort( 'Branch' , 'string' )
+ IPrintGate = Print.GetInPort( 'Gate' )
+ OPrinta = Print.OutPort( 'a' , 'long' )
+ OPrintBranch = Print.OutPort( 'Branch' , 'string' )
+ OPrintGate = Print.GetOutPort( 'Gate' )
+
+ PyPrint_1 = []
+ PyPrint_1.append( 'def Print_1(a,Branch) : ' )
+ PyPrint_1.append( ' print "Print ",Branch ' )
+ PyPrint_1.append( ' return a,Branch ' )
+ Print_1 = GraphSwitch_1_1.INode( 'Print_1' , PyPrint_1 )
+ Print_1.SetName( 'Print_1' )
+ Print_1.SetAuthor( '' )
+ Print_1.SetComment( 'Compute Node' )
+ Print_1.Coords( 639 , 263 )
+ IPrint_1a = Print_1.InPort( 'a' , 'long' )
+ IPrint_1Branch = Print_1.InPort( 'Branch' , 'string' )
+ IPrint_1Gate = Print_1.GetInPort( 'Gate' )
+ OPrint_1a = Print_1.OutPort( 'a' , 'long' )
+ OPrint_1Branch = Print_1.OutPort( 'Branch' , 'string' )
+ OPrint_1Gate = Print_1.GetOutPort( 'Gate' )
+
+ # Creation of Loop Nodes
+ PyInitLoopSwitch = []
+ PyInitLoopSwitch.append( 'def InitLoop(Index,Min,Max) : ' )
+ PyInitLoopSwitch.append( ' Index = Max ' )
+ PyInitLoopSwitch.append( ' return Index,Min,Max ' )
+ PyMoreInitLoopSwitch = []
+ PyMoreInitLoopSwitch.append( 'def MoreLoop(Index,Min,Max) : ' )
+ PyMoreInitLoopSwitch.append( ' if Index >= Min : ' )
+ PyMoreInitLoopSwitch.append( ' DoLoop = 1 ' )
+ PyMoreInitLoopSwitch.append( ' else : ' )
+ PyMoreInitLoopSwitch.append( ' DoLoop = 0 ' )
+ PyMoreInitLoopSwitch.append( ' return DoLoop,Index,Min,Max ' )
+ PyNextInitLoopSwitch = []
+ PyNextInitLoopSwitch.append( 'def NextLoop(Index,Min,Max) : ' )
+ PyNextInitLoopSwitch.append( ' Index = Index - 1 ' )
+ PyNextInitLoopSwitch.append( ' return Index,Min,Max ' )
+ InitLoopSwitch,EndOfInitLoopSwitch = GraphSwitch_1_1.LNode( 'InitLoop' , PyInitLoopSwitch , 'MoreLoop' , PyMoreInitLoopSwitch , 'NextLoop' , PyNextInitLoopSwitch )
+ EndOfInitLoopSwitch.SetName( 'EndOfInitLoopSwitch' )
+ EndOfInitLoopSwitch.SetAuthor( '' )
+ EndOfInitLoopSwitch.SetComment( 'Compute Node' )
+ EndOfInitLoopSwitch.Coords( 1082 , 150 )
+ PyEndOfInitLoopSwitch = []
+ EndOfInitLoopSwitch.SetPyFunction( '' , PyEndOfInitLoopSwitch )
+ IInitLoopSwitchDoLoop = InitLoopSwitch.GetInPort( 'DoLoop' )
+ IInitLoopSwitchIndex = InitLoopSwitch.InPort( 'Index' , 'long' )
+ IInitLoopSwitchMin = InitLoopSwitch.InPort( 'Min' , 'long' )
+ IInitLoopSwitchMax = InitLoopSwitch.InPort( 'Max' , 'long' )
+ IInitLoopSwitchGate = InitLoopSwitch.GetInPort( 'Gate' )
+ OInitLoopSwitchDoLoop = InitLoopSwitch.GetOutPort( 'DoLoop' )
+ OInitLoopSwitchIndex = InitLoopSwitch.GetOutPort( 'Index' )
+ OInitLoopSwitchMin = InitLoopSwitch.GetOutPort( 'Min' )
+ OInitLoopSwitchMax = InitLoopSwitch.GetOutPort( 'Max' )
+ IEndOfInitLoopSwitchDoLoop = EndOfInitLoopSwitch.GetInPort( 'DoLoop' )
+ IEndOfInitLoopSwitchIndex = EndOfInitLoopSwitch.GetInPort( 'Index' )
+ IEndOfInitLoopSwitchMin = EndOfInitLoopSwitch.GetInPort( 'Min' )
+ IEndOfInitLoopSwitchMax = EndOfInitLoopSwitch.GetInPort( 'Max' )
+ IEndOfInitLoopSwitchGate = EndOfInitLoopSwitch.GetInPort( 'Gate' )
+ OEndOfInitLoopSwitchDoLoop = EndOfInitLoopSwitch.GetOutPort( 'DoLoop' )
+ OEndOfInitLoopSwitchIndex = EndOfInitLoopSwitch.GetOutPort( 'Index' )
+ OEndOfInitLoopSwitchMin = EndOfInitLoopSwitch.GetOutPort( 'Min' )
+ OEndOfInitLoopSwitchMax = EndOfInitLoopSwitch.GetOutPort( 'Max' )
+ OEndOfInitLoopSwitchGate = EndOfInitLoopSwitch.GetOutPort( 'Gate' )
+ InitLoopSwitch.SetName( 'InitLoopSwitch' )
+ InitLoopSwitch.SetAuthor( '' )
+ InitLoopSwitch.SetComment( 'Compute Node' )
+ InitLoopSwitch.Coords( 10 , 129 )
+
+ # Creation of Switch Nodes
+ PySwitch = []
+ PySwitch.append( 'from time import * ' )
+ PySwitch.append( 'def Switch(a) : ' )
+ PySwitch.append( ' Branch = 'Negative or null' ' )
+ PySwitch.append( ' if a <= 0 : ' )
+ PySwitch.append( ' return 0,0,a,Branch,1 ' )
+ PySwitch.append( ' if ( a & 1 ) == 0 : ' )
+ PySwitch.append( ' Branch = 'Even' ' )
+ PySwitch.append( ' else : ' )
+ PySwitch.append( ' Branch = 'Odd' ' )
+ PySwitch.append( ' sleep(1) ' )
+ PySwitch.append( ' return a & 1,1-(a&1),a,Branch,0 ' )
+ Switch,EndOfSwitch = GraphSwitch_1_1.SNode( 'Switch' , PySwitch )
+ EndOfSwitch.SetName( 'EndOfSwitch' )
+ EndOfSwitch.SetAuthor( '' )
+ EndOfSwitch.SetComment( 'Compute Node' )
+ EndOfSwitch.Coords( 880 , 150 )
+ PyEndOfSwitch = []
+ EndOfSwitch.SetPyFunction( 'EndSwitch_1' , PyEndOfSwitch )
+ IEndOfSwitcha = EndOfSwitch.InPort( 'a' , 'long' )
+ IEndOfSwitchDefault = EndOfSwitch.GetInPort( 'Default' )
+ OEndOfSwitcha = EndOfSwitch.OutPort( 'a' , 'long' )
+ OEndOfSwitchGate = EndOfSwitch.GetOutPort( 'Gate' )
+ Switch.SetName( 'Switch' )
+ Switch.SetAuthor( '' )
+ Switch.SetComment( 'Compute Node' )
+ Switch.Coords( 195 , 129 )
+ ISwitcha = Switch.InPort( 'a' , 'long' )
+ ISwitchGate = Switch.GetInPort( 'Gate' )
+ OSwitchOdd = Switch.OutPort( 'Odd' , 'long' )
+ OSwitchEven = Switch.OutPort( 'Even' , 'int' )
+ OSwitcha = Switch.OutPort( 'a' , 'int' )
+ OSwitchBranch = Switch.OutPort( 'Branch' , 'string' )
+ OSwitchdefault = Switch.OutPort( 'default' , 'boolean' )
+ OSwitchDefault = Switch.GetOutPort( 'Default' )
+
+ # Creation of Links
+ LIsOddaPrinta = GraphSwitch_1_1.Link( OIsOdda , IPrinta )
+
+ LInitLoopSwitchIndexSwitcha = GraphSwitch_1_1.Link( OInitLoopSwitchIndex , ISwitcha )
+
+ LInitLoopSwitchMinEndOfInitLoopSwitchMin = GraphSwitch_1_1.Link( OInitLoopSwitchMin , IEndOfInitLoopSwitchMin )
+
+ LInitLoopSwitchMaxEndOfInitLoopSwitchMax = GraphSwitch_1_1.Link( OInitLoopSwitchMax , IEndOfInitLoopSwitchMax )
+
+ LIsEvenaPrint_1a = GraphSwitch_1_1.Link( OIsEvena , IPrint_1a )
+
+ LSwitchOddIsOddGate = GraphSwitch_1_1.Link( OSwitchOdd , IIsOddGate )
+
+ LSwitchEvenIsEvenGate = GraphSwitch_1_1.Link( OSwitchEven , IIsEvenGate )
+
+ LSwitchaIsOdda = GraphSwitch_1_1.Link( OSwitcha , IIsOdda )
+
+ LSwitchaIsEvena = GraphSwitch_1_1.Link( OSwitcha , IIsEvena )
+
+ LSwitchBranchPrintBranch = GraphSwitch_1_1.Link( OSwitchBranch , IPrintBranch )
+
+ LSwitchBranchPrint_1Branch = GraphSwitch_1_1.Link( OSwitchBranch , IPrint_1Branch )
+
+ LSwitchDefaultEndOfSwitchDefault = GraphSwitch_1_1.Link( OSwitchDefault , IEndOfSwitchDefault )
+
+ LEndOfSwitchaEndOfInitLoopSwitchIndex = GraphSwitch_1_1.Link( OEndOfSwitcha , IEndOfInitLoopSwitchIndex )
+
+ LPrintaEndOfSwitcha = GraphSwitch_1_1.Link( OPrinta , IEndOfSwitcha )
+
+ LPrint_1aEndOfSwitcha = GraphSwitch_1_1.Link( OPrint_1a , IEndOfSwitcha )
+
+ # Input datas
+ IInitLoopSwitchIndex.Input( 0 )
+ IInitLoopSwitchMin.Input( -5 )
+ IInitLoopSwitchMax.Input( 10 )
+
+ # Output Ports of the graph
+ #OEndOfInitLoopSwitchIndex = EndOfInitLoopSwitch.GetOutPort( 'Index' )
+ #OEndOfInitLoopSwitchMin = EndOfInitLoopSwitch.GetOutPort( 'Min' )
+ #OEndOfInitLoopSwitchMax = EndOfInitLoopSwitch.GetOutPort( 'Max' )
+ #OSwitchdefault = Switch.GetOutPort( 'default' )
+ #OPrintBranch = Print.GetOutPort( 'Branch' )
+ #OPrint_1Branch = Print_1.GetOutPort( 'Branch' )
+ return GraphSwitch_1_1
+
+
+GraphSwitch_1_1 = DefGraphSwitch_1_1()
--- /dev/null
+<!DOCTYPE SuperGraph>
+<supergraph>
+<dataflow>
+<info-list>
+<node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>GraphSwitch_1_1</node-name>
+ <kind>1</kind>
+ <coupled-node>?</coupled-node>
+ <service>
+<service-name>GraphSwitch_1_1</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>InitLoopSwitch__Index</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>InitLoopSwitch__Min</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>InitLoopSwitch__Max</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>EndOfInitLoopSwitch__Index</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>EndOfInitLoopSwitch__Min</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>EndOfInitLoopSwitch__Max</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>boolean</outParameter-type>
+ <outParameter-name>Switch__default</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>string</outParameter-type>
+ <outParameter-name>Print__Branch</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>string</outParameter-type>
+ <outParameter-name>Print_1__Branch</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list/>
+ <creation-date>1/10/2003 - 17:23:54</creation-date>
+ <lastmodification-date>13/1/2005 - 11:21:30</lastmodification-date>
+ <editor-release>1.05</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>?</comment>
+ <x-position>0</x-position>
+ <y-position>0</y-position> </node> </info-list>
+ <node-list>
+<node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>IsOdd</node-name>
+ <kind>3</kind>
+ <coupled-node>?</coupled-node>
+ <service>
+<service-name>IsOdd</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>a</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>a</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>IsOdd</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def IsOdd(a) : ]]></PyFunc>
+ <PyFunc><![CDATA[ print a,"IsOdd (GraphSwitch)" ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep( 1 ) ]]></PyFunc>
+ <PyFunc><![CDATA[ return a ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 11:17:18</creation-date>
+ <lastmodification-date>13/1/2005 - 11:17:18</lastmodification-date>
+ <editor-release>1.05</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Python function</comment>
+ <x-position>388</x-position>
+ <y-position>50</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>InitLoopSwitch</node-name>
+ <kind>4</kind>
+ <coupled-node>EndOfInitLoopSwitch</coupled-node>
+ <service>
+<service-name>InitLoopSwitch</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>Index</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>Min</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>Max</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>Index</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>Min</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>Max</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>InitLoop</FuncName>
+ <PyFunc><![CDATA[def InitLoop(Index,Min,Max) : ]]></PyFunc>
+ <PyFunc><![CDATA[ Index = Max ]]></PyFunc>
+ <PyFunc><![CDATA[ return Index,Min,Max ]]></PyFunc> </PyFunction>
+ <PyFunction>
+<FuncName>MoreLoop</FuncName>
+ <PyFunc><![CDATA[def MoreLoop(Index,Min,Max) : ]]></PyFunc>
+ <PyFunc><![CDATA[ if Index >= Min : ]]></PyFunc>
+ <PyFunc><![CDATA[ DoLoop = 1 ]]></PyFunc>
+ <PyFunc><![CDATA[ else : ]]></PyFunc>
+ <PyFunc><![CDATA[ DoLoop = 0 ]]></PyFunc>
+ <PyFunc><![CDATA[ return DoLoop,Index,Min,Max ]]></PyFunc> </PyFunction>
+ <PyFunction>
+<FuncName>NextLoop</FuncName>
+ <PyFunc><![CDATA[def NextLoop(Index,Min,Max) : ]]></PyFunc>
+ <PyFunc><![CDATA[ Index = Index - 1 ]]></PyFunc>
+ <PyFunc><![CDATA[ return Index,Min,Max ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 11:17:18</creation-date>
+ <lastmodification-date>13/1/2005 - 11:17:18</lastmodification-date>
+ <editor-release>1.05</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>10</x-position>
+ <y-position>129</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>EndOfInitLoopSwitch</node-name>
+ <kind>5</kind>
+ <coupled-node>InitLoopSwitch</coupled-node>
+ <service>
+<service-name>EndOfInitLoopSwitch</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>Index</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>Min</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>Max</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>Index</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>Min</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>Max</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>?</FuncName>
+ <PyFunc><![CDATA[?]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 11:17:18</creation-date>
+ <lastmodification-date>13/1/2005 - 11:17:18</lastmodification-date>
+ <editor-release>1.05</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>1082</x-position>
+ <y-position>150</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>IsEven</node-name>
+ <kind>3</kind>
+ <coupled-node>?</coupled-node>
+ <service>
+<service-name>IsEven</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>a</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>a</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>IsEven</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def IsEven(a) : ]]></PyFunc>
+ <PyFunc><![CDATA[ print a,"IsEven (GraphSwitch)" ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep( 1 ) ]]></PyFunc>
+ <PyFunc><![CDATA[ return a ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 11:17:18</creation-date>
+ <lastmodification-date>13/1/2005 - 11:17:18</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>395</x-position>
+ <y-position>334</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>Switch</node-name>
+ <kind>6</kind>
+ <coupled-node>EndOfSwitch</coupled-node>
+ <service>
+<service-name>Switch</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>a</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>Odd</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>int</outParameter-type>
+ <outParameter-name>Even</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>int</outParameter-type>
+ <outParameter-name>a</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>string</outParameter-type>
+ <outParameter-name>Branch</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>boolean</outParameter-type>
+ <outParameter-name>default</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>Switch</FuncName>
+ <PyFunc><![CDATA[from time import * ]]></PyFunc>
+ <PyFunc><![CDATA[def Switch(a) : ]]></PyFunc>
+ <PyFunc><![CDATA[ Branch = 'Negative or null' ]]></PyFunc>
+ <PyFunc><![CDATA[ if a <= 0 : ]]></PyFunc>
+ <PyFunc><![CDATA[ return 0,0,a,Branch,1 ]]></PyFunc>
+ <PyFunc><![CDATA[ if ( a & 1 ) == 0 : ]]></PyFunc>
+ <PyFunc><![CDATA[ Branch = 'Even' ]]></PyFunc>
+ <PyFunc><![CDATA[ else : ]]></PyFunc>
+ <PyFunc><![CDATA[ Branch = 'Odd' ]]></PyFunc>
+ <PyFunc><![CDATA[ sleep(1) ]]></PyFunc>
+ <PyFunc><![CDATA[ return a & 1,1-(a&1),a,Branch,0 ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 11:17:18</creation-date>
+ <lastmodification-date>13/1/2005 - 11:17:18</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>195</x-position>
+ <y-position>129</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>EndOfSwitch</node-name>
+ <kind>7</kind>
+ <coupled-node>Switch</coupled-node>
+ <service>
+<service-name>EndOfSwitch</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>a</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>a</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>EndSwitch_1</FuncName>
+ <PyFunc><![CDATA[?]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 11:17:18</creation-date>
+ <lastmodification-date>13/1/2005 - 11:17:18</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>880</x-position>
+ <y-position>150</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>Print</node-name>
+ <kind>3</kind>
+ <coupled-node>?</coupled-node>
+ <service>
+<service-name>Void</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>a</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>string</inParameter-type>
+ <inParameter-name>Branch</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>a</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>string</outParameter-type>
+ <outParameter-name>Branch</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>Print</FuncName>
+ <PyFunc><![CDATA[def Print(a,Branch) : ]]></PyFunc>
+ <PyFunc><![CDATA[ print "Print ",Branch ]]></PyFunc>
+ <PyFunc><![CDATA[ return a,Branch ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 11:17:18</creation-date>
+ <lastmodification-date>13/1/2005 - 11:17:18</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>639</x-position>
+ <y-position>63</y-position> </node>
+ <node>
+<component-name>?</component-name>
+ <interface-name>?</interface-name>
+ <node-name>Print_1</node-name>
+ <kind>3</kind>
+ <coupled-node>?</coupled-node>
+ <service>
+<service-name>Print_1</service-name>
+ <inParameter-list>
+<inParameter>
+<inParameter-type>long</inParameter-type>
+ <inParameter-name>a</inParameter-name> </inParameter>
+ <inParameter>
+<inParameter-type>string</inParameter-type>
+ <inParameter-name>Branch</inParameter-name> </inParameter> </inParameter-list>
+ <outParameter-list>
+<outParameter>
+<outParameter-type>long</outParameter-type>
+ <outParameter-name>a</outParameter-name> </outParameter>
+ <outParameter>
+<outParameter-type>string</outParameter-type>
+ <outParameter-name>Branch</outParameter-name> </outParameter> </outParameter-list> </service>
+ <DataStream-list/>
+ <PyFunction-list>
+<PyFunction>
+<FuncName>Print_1</FuncName>
+ <PyFunc><![CDATA[def Print_1(a,Branch) : ]]></PyFunc>
+ <PyFunc><![CDATA[ print "Print ",Branch ]]></PyFunc>
+ <PyFunc><![CDATA[ return a,Branch ]]></PyFunc> </PyFunction> </PyFunction-list>
+ <creation-date>13/1/2005 - 11:20:58</creation-date>
+ <lastmodification-date>13/1/2005 - 11:20:58</lastmodification-date>
+ <editor-release>2.0</editor-release>
+ <author>?</author>
+ <container>?</container>
+ <comment>Compute Node</comment>
+ <x-position>639</x-position>
+ <y-position>263</y-position> </node> </node-list>
+ <link-list>
+<link>
+<fromnode-name>IsOdd</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>Print</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>InitLoopSwitch</fromnode-name>
+ <fromserviceparameter-name>DoLoop</fromserviceparameter-name>
+ <tonode-name>EndOfInitLoopSwitch</tonode-name>
+ <toserviceparameter-name>DoLoop</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>InitLoopSwitch</fromnode-name>
+ <fromserviceparameter-name>Index</fromserviceparameter-name>
+ <tonode-name>Switch</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>InitLoopSwitch</fromnode-name>
+ <fromserviceparameter-name>Min</fromserviceparameter-name>
+ <tonode-name>EndOfInitLoopSwitch</tonode-name>
+ <toserviceparameter-name>Min</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>InitLoopSwitch</fromnode-name>
+ <fromserviceparameter-name>Max</fromserviceparameter-name>
+ <tonode-name>EndOfInitLoopSwitch</tonode-name>
+ <toserviceparameter-name>Max</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>EndOfInitLoopSwitch</fromnode-name>
+ <fromserviceparameter-name>DoLoop</fromserviceparameter-name>
+ <tonode-name>InitLoopSwitch</tonode-name>
+ <toserviceparameter-name>DoLoop</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>IsEven</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>Print_1</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>Odd</fromserviceparameter-name>
+ <tonode-name>IsOdd</tonode-name>
+ <toserviceparameter-name>Gate</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>Even</fromserviceparameter-name>
+ <tonode-name>IsEven</tonode-name>
+ <toserviceparameter-name>Gate</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>IsOdd</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>IsEven</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>Branch</fromserviceparameter-name>
+ <tonode-name>Print</tonode-name>
+ <toserviceparameter-name>Branch</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>Branch</fromserviceparameter-name>
+ <tonode-name>Print_1</tonode-name>
+ <toserviceparameter-name>Branch</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>Switch</fromnode-name>
+ <fromserviceparameter-name>Default</fromserviceparameter-name>
+ <tonode-name>EndOfSwitch</tonode-name>
+ <toserviceparameter-name>Default</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>EndOfSwitch</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>EndOfInitLoopSwitch</tonode-name>
+ <toserviceparameter-name>Index</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>Print</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>EndOfSwitch</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list/> </link>
+ <link>
+<fromnode-name>Print_1</fromnode-name>
+ <fromserviceparameter-name>a</fromserviceparameter-name>
+ <tonode-name>EndOfSwitch</tonode-name>
+ <toserviceparameter-name>a</toserviceparameter-name>
+ <coord-list/> </link> </link-list>
+ <data-list>
+<data>
+<fromnode-name>GraphSwitch_1_1</fromnode-name>
+ <fromserviceparameter-name>InitLoopSwitch__Index</fromserviceparameter-name>
+ <tonode-name>InitLoopSwitch</tonode-name>
+ <toserviceparameter-name>Index</toserviceparameter-name>
+ <data-value>
+<value-type>3</value-type>
+ <value>0</value> </data-value>
+ <coord-list/> </data>
+ <data>
+<fromnode-name>GraphSwitch_1_1</fromnode-name>
+ <fromserviceparameter-name>InitLoopSwitch__Min</fromserviceparameter-name>
+ <tonode-name>InitLoopSwitch</tonode-name>
+ <toserviceparameter-name>Min</toserviceparameter-name>
+ <data-value>
+<value-type>3</value-type>
+ <value>-5</value> </data-value>
+ <coord-list/> </data>
+ <data>
+<fromnode-name>GraphSwitch_1_1</fromnode-name>
+ <fromserviceparameter-name>InitLoopSwitch__Max</fromserviceparameter-name>
+ <tonode-name>InitLoopSwitch</tonode-name>
+ <toserviceparameter-name>Max</toserviceparameter-name>
+ <data-value>
+<value-type>3</value-type>
+ <value>10</value> </data-value>
+ <coord-list/> </data> </data-list> </dataflow></supergraph>