[jboss-user] [JBoss jBPM] - Re: JBPM TaskCreation at RunTime

abbasshah do-not-reply at jboss.com
Tue Jul 18 13:26:09 EDT 2006


This the code of ActionHandler which creats Tasks

anonymous wrote : public class OnNodeEnter implements ActionHandler {
  |     
  |     private final static Log log = LogFactory.getLog( OnNodeEnter.class );   
  |     
  |     public void execute(ExecutionContext executionContext) throws Exception {
  |         
  |         System.out.println("OnCreation-->- Start");
  |         
  |         Token token = executionContext.getToken();
  |         TaskMgmtInstance tmi = executionContext.getTaskMgmtInstance();
  |         TaskNode taskNode = (TaskNode) executionContext.getNode();
  |         
  |       
  |         Task doRecalc = taskNode.getTask("MG_CALL_AGREED");
  |         tmi.createTaskInstance(doRecalc, token);
  | 
  |         Task doRecalc3 = taskNode.getTask("MG_CALL_SYSTASK_DATA_UPDATE");
  |         tmi.createTaskInstance(doRecalc3, token);
  | 
  |         System.out.println("OnCreation-->- END");
  |         
  |     }
  |     
}



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

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



More information about the jboss-user mailing list