[jboss-user] [JBoss jBPM] - Re: how to use Decision nodes??????

minam97531 do-not-reply at jboss.com
Mon Jul 14 09:52:10 EDT 2008


oops, sorry! here's the code:


  | <?xml version="1.0" encoding="UTF-8"?>
  | <process-definition
  |         xmlns="urn:jbpm.org:jpdl-3.1"
  |         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  |         xsi:schemaLocation="urn:jbpm.org:jpdl-3.1 urn:jbpm.org/xsd/jpdl-3.1.xsd" name="mytest">
  | <!--  Event Logging --> 
  | <event type="node-enter">
  | <script>System.out.println("Entering node " + node.getName());</script> 
  | </event>
  | <event type="node-leave">
  | <script>System.out.println("Leaving node " + node.getName());</script> 
  |   </event>
  | <!--Swimlane-->
  | <swimlane name="buyer" />
  | <start-state name="start">
  | <task swimlane="user">
  | <controller>
  | <variable name="textarea:comments" /> 
  | </controller>
  | </task>
  | <transition name="ok" to="state1"></transition>
  | </start-state>
  | <state name="state1">
  | <event type="node-leave">
  | <script>
  | <variable name="aName" mapped-name="mappedName"/>
  | <expression>executionContext.setVariable("mappedName", 7);</expression>
  | </script>
  | </event>
  | <transition name="" to="decision1"></transition>
  | </state>
  | <decision name="decision1">
  | <transition name="tr1" to="task1">
  | <condition expression="#{contextInstance.variables.mappedName le 5}"/>
  | </transition>
  | <transition name="tr2" to="task2">
  | <condition expression="#{contextInstance.variables.mappedName ge 5}"/>
  | </transition>
  | </decision>
  | <task-node name="task1">
  | <task swimlane="buyer">
  | <controller>
  | <variable name="text:name" access="read,write,required" /> 
  | <variable name="number:tel" access="read,write,required" /> 
  | </controller>
  | </task>
  | <transition name="finish" to="end" /> 
  | </task-node>
  | <task-node name="task2">
  | <task swimlane="buyer">
  | <controller>
  | <variable name="textarea:address" access="read,write,required" /> 
  | </controller>
  | </task>
  | <transition name="submit" to="end" /> 
  | </task-node>
  | <end-state name="end"></end-state>
  | </process-definition>
  | 

and i forgot to say i appreciate any help!
thanks! 

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4164243#4164243

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4164243



More information about the jboss-user mailing list