Package de.danet.an.workflow.api

Examples of de.danet.an.workflow.api.DefaultRequester


      procDefDir = workflowService.processDefinitionDirectory();
      procDir = workflowService.processDirectory();
      ProcessMgr pmgr = procDefDir.processMgr
    ("timing", "cancel_test");
      WfProcess process
    = pmgr.createProcess(new DefaultRequester (workflowService));
      process.start();
      assertTrue (stateReached (process, "closed.completed"));
      ProcessData pd = process.processContext();
      assertTrue ("EXPIRED".equals(pd.get("wait2Result")));
      assertTrue ("CANCELED".equals(pd.get("wait1Result")));
View Full Code Here


        throws Exception {
  ProcessDefinitionDirectory pdd = null;
  try {
      pdd = workflowService().processDefinitionDirectory();
      WfProcessMgr pmgr = pdd.processMgr(pkgId, prcId);
      return pmgr.createProcess (new DefaultRequester(workflowService()));
  } finally {
      workflowService().release (pdd);
  }
    }
View Full Code Here

     *             A21 --> A22 --> A23 --> A24
     * </pre>
     * without any branched activity.
     */
    public void processjut2() throws Exception {
  WfRequester req = new DefaultRequester(workflowService);
  // create the process
  WfProcess process = createProcess("ut-process", "jut2", req);
  assertTrue(process.state().equals("open.not_running.not_started"));
  // start the process
  process.start();
View Full Code Here

     *             A41 --|        --| --> A44
     *                   |--> A43 --|
     * </pre>
     */
    public void processjut4() throws Exception {
  WfRequester req = new DefaultRequester(workflowService);
  // create the process
  WfProcess process = createProcess("ut-process", "jut4", req);
  assertTrue(process.state().equals("open.not_running.not_started"));
  // start the process
  process.start();
View Full Code Here

    /**
     * Test a complex process definition.
     * The activities will be finished manually.
     */
    public void processjut6() throws Exception {
  WfRequester req = new DefaultRequester(workflowService);
  // create the process
  WfProcess process = createProcess("ut-process", "jut6", req);
  assertTrue(process.state().equals("open.not_running.not_started"));
  // start the process
  process.start();
View Full Code Here

  //suspendresumeProcess();
    }

    //Abort Process
    private void abortProcess() throws Exception {
  WfRequester req = new DefaultRequester(workflowService);
  WfProcess process = createProcess("ut-process", "jut2", req);
  assertTrue(process.state().equals("open.not_running.not_started"));
  process.start();
  assertTrue(process.state().startsWith("open.running"));
  process.suspend();
View Full Code Here

  assertTrue(process.state().equals("closed.aborted"));
    }

    //Suspend Process then resume it
    private void suspendresumeProcess() throws Exception {
  WfRequester req = new DefaultRequester(workflowService);
  WfProcess process = createProcess("ut-process", "jut2", req);
  assertTrue(process.state().equals("open.not_running.not_started"));
  process.start();
  assertTrue(process.state().equals("open.running"));
  process.suspend();
View Full Code Here

     * 2.) remove closed process
     * Please note definitions matching the (logical) code flow, e.g. start and
     * finish mode of the corresponding activities.
     */
    public void removejut1() throws Exception {
  WfRequester req = new DefaultRequester(workflowService);
  // create the process
  Process process = (Process)(createProcess("ut-process", "jut1", req));
  assertTrue(process.state().equals("open.not_running.not_started"));
  // start the process
  process.start();
View Full Code Here

     * A process can be removed automatically only if its state is CLOSED and
     * the extendedAttribute of removeClosedProcess in procss definition is
     * AUTOMATIC (Default: AUTOMATIC).
     */
    public void removeClosedProcessjut1() throws Exception {
  WfRequester req = new DefaultRequester(workflowService);
  ProcessDirectory procDir = processDirectory();
  // create the process
  Process process = (Process)(createProcess("ut-process", "jut5", req));
  String processKey = process.key();
  assertTrue(process.state().equals("open.not_running.not_started"));
View Full Code Here

      procDefDir = workflowService.processDefinitionDirectory();
      procDir = workflowService.processDirectory();
      ProcessMgr pmgr = procDefDir
    .processMgr ("ExceptionTests", "defaultMapping");
      WfProcess process
    = pmgr.createProcess(new DefaultRequester (workflowService));
      process.start();
      assertTrue (stateReached (process, "closed.completed"));
      boolean found = false;
      for (Iterator i = process.steps().iterator(); i.hasNext();) {
          WfActivity act = (WfActivity)i.next ();
View Full Code Here

TOP

Related Classes of de.danet.an.workflow.api.DefaultRequester

Copyright © 2018 www.massapicom. 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.