0 Replies Latest reply on Oct 19, 2005 1:02 AM by a s

    how to loop over same node

    a s Newbie

      This is my process definition which describes the process of creating tasks, assiging tasks and then completing tasks.
      I now need to be able to assign/re-assign tasks any number of times.
      So the 'assign action' state-node needs to be called as many number of times.
      How should i change my process definition to iterate through the same node.
      Should i introduce a decision node above my 'assign action' state-node where i make a decision to either assign an action / complete an action .
      If assign actin is chosen i tranistion to assign action node and propogate execution back to the decsion node where it waits.
      Should this be my approach , please suggest ?

      <?xml version="1.0" encoding="UTF-8"?>
      <process-definition name="test3">
       <start-state name="start">
       <transition name="tr1" to="create action"></transition>
       <task-node name="create action">
       <task name="task1">
       <assignment class="com.jbay.CreateTaskHandler"></assignment>
       <transition name="tr1" to="assign action"></transition>
       <state name="assign action">
       <event type="node-enter">
       <action name="AssignAction" class="com.jbay.AssignTaskHandler"></action>
       <transition name="tr2" to="complete action"></transition>
       <state name="complete action">
       <event type="node-enter">
       <action name="CompleteAction" class="com.jbay.CompleteTaskHandler"></action>
       <transition name="tr3" to="end1"></transition>
       <end-state name="end1"></end-state>