Package org.jbpm.graph.exe

Examples of org.jbpm.graph.exe.Token.signal()


     
      // start workflow
      Token token = processInstance.getRootToken();
      GraphSession graphSess = jbpmContext.getGraphSession();
      try {
        token.signal();
      } catch (Exception e) {
        if(e.getCause() instanceof OpenOfficeConnectionException ) {
          executionMsg = msgBuilder.getMessage("dossier.errorConnectionOO", "component_dossier_messages");
        }
          throw e;
View Full Code Here


            if (variables != null && variables.size() > 0)
                token.getProcessInstance().getContextInstance().addVariables(variables);

            if (transitionName == null) {
                token.signal();
            }
            else {
                token.signal(transitionName);
            }
            return token;
View Full Code Here

            if (transitionName == null) {
                token.signal();
            }
            else {
                token.signal(transitionName);
            }
            return token;
        }
    }
View Full Code Here

    contextInstance.setVariable("processDefinitionName",
        processDefinitionName);
    Order order = new Order(300);
    contextInstance.setVariable("order", order);
    Token token = processInstance.getRootToken();
    token.signal();
    return id;
  }

  public long acquireTask(String actorId) {
    List<TaskInstance> tasklist = getTaskList(actorId);
View Full Code Here

    contextInstance = processInstance.getContextInstance();
    contextInstance.setVariable("processDefinitionName",
        processDefinitionName);
    contextInstance.setVariable("customId", "abc");
    Token token = processInstance.getRootToken();
    token.signal();
    return processInstanceId;

  }

View Full Code Here

    Order order = new Order(300);
    Customer customer = new Customer("Fred", new Integer(5), new Integer(25), new Long (100000));
    contextInstance.setVariable("order", order);
    contextInstance.setVariable("customer", customer);
    Token token = processInstance.getRootToken();
    token.signal();
    return id;
  }

  public ProcessInstance getProcessInstance(long processInstanceId) {
    ProcessInstance processInstance = (ProcessInstance) jbpmContext.loadProcessInstanceForUpdate(processInstanceId);
View Full Code Here

       processInstance.getContextInstance().setVariable("workingMemoryVariable", workingMemory);   
       processInstance.getContextInstance().setVariable("quoteWorkingObject", quoteWorkingObject);   
       System.out.println("Working Memory is: " + workingMemory);
       Token token = processInstance.getRootToken();
         
       token.signal();


      // Build a QuoteObject from the QuoteWorkingObject
      Quote quote = quoteWorkingObject.getQuote();
     
View Full Code Here

  public void testOpenedOpen() {
    ProcessInstance processInstance = new ProcessInstance(doorProcess);
    Token token = processInstance.getRootToken();
    token.setNode(open);
    try {
      token.signal("open");
      fail("expected exception");
    } catch (JbpmException e) {
    }
  }
View Full Code Here

  public void testOpenedLock() {
    ProcessInstance processInstance = new ProcessInstance(doorProcess);
    Token token = processInstance.getRootToken();
    token.setNode(open);
    token.signal("lock");
    assertEquals("Open Locked", token.getNode().getName());
  }

  public void testOpenedClose() {
    ProcessInstance processInstance = new ProcessInstance(doorProcess);
View Full Code Here

  public void testOpenedClose() {
    ProcessInstance processInstance = new ProcessInstance(doorProcess);
    Token token = processInstance.getRootToken();
    token.setNode(open);
    token.signal("close");
    assertEquals("Closed", token.getNode().getName());
  }

  public void testOpenedUnlock() {
    ProcessInstance processInstance = new ProcessInstance(doorProcess);
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.