Package de.danet.an.workflow.api

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


     * realized. Override this method to change this way.
     * @exception Exception if an error occurs
     */
    protected void setUp() throws Exception {
  super.setUp();
  WorkflowService wfs = WorkflowServiceFactory.newInstance()
      .newWorkflowService();
  try {
      defDir = wfs.processDefinitionDirectory();
  } catch(RemoteException exc) {
      System.err.println("Process definition directory not accessible: "
             + exc.getMessage());
      System.exit(-1);
  }

  procDir = wfs.processDirectory();
  requester = new DefaultRequester(wfs);
  importProcessDefinition("/process/deadline.xml");
    }
View Full Code Here


     * realized. Override this method to change this way.
     * @exception Exception if an error occurs
     */
    protected void setUp() throws Exception {
  super.setUp();
  WorkflowService wfs = WorkflowServiceFactory.newInstance()
      .newWorkflowService();
  try {
      defDir = wfs.processDefinitionDirectory();
  } catch(RemoteException exc) {
      System.err.println("Process definition directory not accessible: "
             + exc.getMessage());
      System.exit(-1);
  }
  // Read process definitions
  importProcessDefinition("/procdef/full.xml");
  importProcessDefinition("/procdef/minimal.xml");
  procDir = wfs.processDirectory();
  requester = new DefaultRequester(wfs);
    }
View Full Code Here

     * realized. Override this method to change this way.
     * @exception Exception if an error occurs
     */
    protected void setUp() throws Exception {
  super.setUp();
  WorkflowService wfs = WorkflowServiceFactory.newInstance()
      .newWorkflowService();
  try {
      defDir = wfs.processDefinitionDirectory();
  } catch(RemoteException exc) {
      System.err.println("Process definition directory not accessible: "
             + exc.getMessage());
      System.exit(-1);
  }

  procDir = wfs.processDirectory();
  requester = new DefaultRequester(wfs);
    }
View Full Code Here

     * realized. Override this method to change this way.
     * @exception Exception if an error occurs
     */
    protected void setUp() throws Exception {
  super.setUp();
  WorkflowService wfs = WorkflowServiceFactory.newInstance()
      .newWorkflowService();
  try {
      defDir = new WrappedProcessDefinitionDirectory
    (wfs.processDefinitionDirectory());
  } catch(RemoteException exc) {
      System.err.println("Process definition directory not accessible: "
             + exc.getMessage());
      System.exit(-1);
  }

  // Read process definitions
  importProcessDefinition("/procdef/full.xml");
  importProcessDefinition("/procdef/minimal.xml");
  importProcessDefinition("/procdef/blockActivities.xml");
  procDir = wfs.processDirectory();
  requester = new DefaultRequester(wfs);
    }
View Full Code Here

     * realized. Override this method to change this way.
     * @exception Exception if an error occurs
     */
    protected void setUp() throws Exception {
  super.setUp();
  WorkflowService wfs = WorkflowServiceFactory.newInstance()
      .newWorkflowService();
  try {
      defDir = wfs.processDefinitionDirectory();
  } catch(RemoteException exc) {
      System.err.println("Process definition directory not accessible: "
             + exc.getMessage());
      System.exit(-1);
  }

  procDir = wfs.processDirectory();
  requester = new DefaultRequester(wfs);
  importProcessDefinition("/process/deferredChoice.xml");
    }
View Full Code Here

     * realized. Override this method to change this way.
     * @exception Exception if an error occurs
     */
    protected void setUp() throws Exception {
  super.setUp();
  WorkflowService wfs = WorkflowServiceFactory.newInstance()
      .newWorkflowService();
  try {
      defDir = wfs.processDefinitionDirectory();
  } catch(RemoteException exc) {
      System.err.println("Process definition directory not accessible: "
             + exc.getMessage());
      System.exit(-1);
  }
  // Read process definitions
  importProcessDefinition("/procdef/full.xml");
  importProcessDefinition("/procdef/minimal.xml");
  procDir = wfs.processDirectory();
  requester = new DefaultRequester(wfs);
    }
View Full Code Here

     * realized. Override this method to change this way.
     * @exception Exception if an error occurs
     */
    protected void setUp() throws Exception {
  super.setUp();
  WorkflowService wfs = WorkflowServiceFactory.newInstance()
      .newWorkflowService();
  try {
      defDir = wfs.processDefinitionDirectory();
  } catch(RemoteException exc) {
      System.err.println("Process definition directory not accessible: "
             + exc.getMessage());
      System.exit(-1);
  }
View Full Code Here

     * realized. Override this method to change this way.
     * @exception Exception if an error occurs
     */
    protected void setUp() throws Exception {
  super.setUp();
  WorkflowService wfs = WorkflowServiceFactory.newInstance()
      .newWorkflowService();
  try {
      defDir = new WrappedProcessDefinitionDirectory
    (wfs.processDefinitionDirectory());
  } catch(RemoteException exc) {
      System.err.println("Process definition directory not accessible: "
             + exc.getMessage());
      System.exit(-1);
  }

  // Read process definitions
  importProcessDefinition("/procdef/full.xml");
  importProcessDefinition("/procdef/minimal.xml");
  importProcessDefinition("/procdef/blockActivities.xml");
  procDir = wfs.processDirectory();
  requester = new DefaultRequester(wfs);
    }
View Full Code Here

    public Map startAndWait ()
        throws InvalidKeyException, NotEnabledException,
            InvalidRequesterException, RequesterRequiredException,
            CannotStartException, AlreadyRunningException,
            CannotRemoveException {
        WorkflowService workflowService = null;
        Channel chan = null;
        try {
            WorkflowServiceFactory wsf = WorkflowServiceFactory.newInstance();
            workflowService = wsf.newWorkflowService();
       
            ProcessDefinitionDirectory procDefDir
                = workflowService.processDefinitionDirectory();
            ProcessDirectory procDir = workflowService.processDirectory();
            ProcessMgr pmgr = procDefDir.processMgr
                ("chabacc", "chabacc_test_sender");
            WfProcess process
                = pmgr.createProcess(new DefaultRequester (workflowService));
            chan = workflowService.getChannel(process, "test_channel");
            process.start();
            Map pd = chan.receiveMessage();
            return pd;
        } catch (RemoteException e) {
            throw new EJBException (e);
        } finally {
            workflowService.release(chan);
            workflowService.release(workflowService);
        }
    }
View Full Code Here

    public Map startAndWait (long timeout)
        throws InvalidKeyException, NotEnabledException,
            InvalidRequesterException, RequesterRequiredException,
            CannotStartException, AlreadyRunningException,
            CannotRemoveException {
        WorkflowService workflowService = null;
        Channel chan = null;
        try {
            WorkflowServiceFactory wsf = WorkflowServiceFactory.newInstance();
            workflowService = wsf.newWorkflowService();
       
            ProcessDefinitionDirectory procDefDir
                = workflowService.processDefinitionDirectory();
            ProcessDirectory procDir = workflowService.processDirectory();
            ProcessMgr pmgr = procDefDir.processMgr
                ("chabacc", "chabacc_test_sender");
            WfProcess process
                = pmgr.createProcess(new DefaultRequester (workflowService));
            chan = workflowService.getChannel(process, "test_channel");
            process.start();
            Map pd = chan.receiveMessage(timeout);
            return pd;
        } catch (RemoteException e) {
            throw new EJBException (e);
        } finally {
          workflowService.release (chan);
            workflowService.release(workflowService);
        }
    }
View Full Code Here

TOP

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

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.