Package de.danet.an.workflow.api

Examples of de.danet.an.workflow.api.ProcessMgr.createProcess()


      processRemoved = true;
  }
  assertTrue(processRemoved);

  mgr = defDir.processMgr("SystemTest", "completeRemoval");
  proc = mgr.createProcess(requester);
  procKey = proc.key();
  proc.start();
  // Assure that process has been removed automatically
  processRemoved = false;
  int maxRetries = 5;
View Full Code Here


     * @exception Exception if an error occurs
     */
    public void testPath() throws Exception {
  List msgList = importProcessDefinition("/process/transition1.xml");
  ProcessMgr mgr = defDir.processMgr("SystemTest", "simplePath");
  WfProcess proc = mgr.createProcess(requester);
  proc.start();
  // Wait for completion
  assertTrue(stateReached(proc, "closed.completed",
        "closed.completed"));
  ProcessData data = proc.processContext();
View Full Code Here

  assertTrue(((String)data.get("TransitionPath"))
       .equals("PATH:act1:act2:act3"));
  procDir.removeProcess(proc);

  mgr = defDir.processMgr("SystemTest", "block_2_in_2_out");
  proc = mgr.createProcess(requester);
  proc.start();
  // Wait for completion
  assertTrue("Process not completed in time",
       stateReached(proc, "closed.completed",
        "closed.completed"));
View Full Code Here

  }

  List msgList = importProcessDefinition("/process/loop.xml");
  assertTrue(msgList.size() == 0);
  ProcessMgr mgr = defDir.processMgr("SystemTest", "loop_3_times");
  WfProcess proc = mgr.createProcess(requester);
  proc.start();
  // Wait for completion
  assertTrue(stateReached(proc, "closed.completed"));
  ProcessData data = proc.processContext();
  assertTrue(((Long)data.get("Counter")).intValue() == 3);
View Full Code Here

     * @exception Exception if an error occurs
     */
    public void testCascade() throws Exception {
  // Uses XPDL imported by testLoop
  ProcessMgr mgr = defDir.processMgr("SystemTest", "cascade");
  WfProcess proc = mgr.createProcess(requester);
  proc.start();
  // Wait for completion
  assertTrue(stateReached(proc, "closed.completed"));
  ProcessData data = proc.processContext();
  assertTrue(((Boolean)data.get("completed"))
View Full Code Here

//   WfProcess proc2 = mgrFull.createProcess(requester);
//   WfProcess proc3 = mgrFull.createProcess(requester);
  WrappedProcess proc1
      = new WrappedProcess(mgrMin.createProcess(requester));
  WrappedProcess proc2
      = new WrappedProcess(mgrFull.createProcess(requester));
  WrappedProcess proc3
      = new WrappedProcess(mgrFull.createProcess(requester));
  // Test attributes of processes without existing process definition
  defDir.removeProcessDefinition("SystemTest_minimal", "minimal");
  defDir.removeProcessDefinition("SystemTest_full", "full");
View Full Code Here

     * @exception Exception if an error occurs
     */
    public void testScrabble() throws Exception {
  // Uses XPDL imported by testLoop
  ProcessMgr mgr = defDir.processMgr("SystemTest", "scrabble");
  WfProcess proc = mgr.createProcess(requester);
  proc.start();
  // Wait for completion
  assertTrue(stateReached(proc, "closed.completed"));
  ProcessData data = proc.processContext();
  assertTrue(((String)data.get("compound")).equals("DANET"));
View Full Code Here

  WrappedProcess proc1
      = new WrappedProcess(mgrMin.createProcess(requester));
  WrappedProcess proc2
      = new WrappedProcess(mgrFull.createProcess(requester));
  WrappedProcess proc3
      = new WrappedProcess(mgrFull.createProcess(requester));
  // Test attributes of processes without existing process definition
  defDir.removeProcessDefinition("SystemTest_minimal", "minimal");
  defDir.removeProcessDefinition("SystemTest_full", "full");
  boolean procdefRemoved = false;
  try {
View Full Code Here

     * @exception Exception if an error occurs
     */
    public void testAndSplitOtherwise() throws Exception {
  // Uses XPDL imported by testLoop
  ProcessMgr mgr = defDir.processMgr("SystemTest", "andOtherwiseTest");
  WfProcess proc = mgr.createProcess(requester);
  proc.start();
  // Wait for completion
  assertTrue(stateReached(proc, "closed.completed"));
  ProcessData data = proc.processContext();
  assertTrue(((Boolean)data.get("Success")).equals(Boolean.TRUE));
View Full Code Here

//   WfProcess proc2 = mgrFull.createProcess(requester);
//   WfProcess proc3 = mgrFull.createProcess(requester);
  WrappedProcess proc1
      = new WrappedProcess(mgrMin.createProcess(requester));
  WrappedProcess proc2
      = new WrappedProcess(mgrFull.createProcess(requester));
  WrappedProcess proc3
      = new WrappedProcess(mgrFull.createProcess(requester));

  // Test activity of process 1
  assertTrue(proc1.steps().size() == 1);
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.