Examples of StartFormHandler


Examples of org.activiti.engine.impl.form.StartFormHandler

    }

    commandContext.getHistoryManager()
      .reportFormPropertiesSubmitted(processInstance, properties, null);
   
    StartFormHandler startFormHandler = processDefinition.getStartFormHandler();
    startFormHandler.submitFormProperties(properties, processInstance);

    processInstance.start();
   
    return processInstance;
  }
View Full Code Here

Examples of org.activiti.engine.impl.form.StartFormHandler

    if(processDefinition.getInitial() != null) {
      for (Element startEventElement : startEventElements) {
       
        if(startEventElement.attribute("id").equals(processDefinition.getInitial().getId())) {
         
          StartFormHandler startFormHandler;
          String startFormHandlerClassName = startEventElement.attributeNS(BpmnParser.ACTIVITI_BPMN_EXTENSIONS_NS, "formHandlerClass");
          if (startFormHandlerClassName != null) {
            startFormHandler = (StartFormHandler) ReflectUtil.instantiate(startFormHandlerClassName);
          } else {
            startFormHandler = new DefaultStartFormHandler();
          }
          startFormHandler.parseConfiguration(startEventElement, deployment, processDefinition, this);
     
          processDefinition.setStartFormHandler(startFormHandler);
        }
       
      }
View Full Code Here

Examples of org.activiti.engine.impl.form.StartFormHandler

      .getDeploymentCache()
      .findDeployedProcessDefinitionById(processDefinitionId);
    if (processDefinition == null) {
      throw new ActivitiException("Process Definition '" + processDefinitionId +"' not found");
    }
    StartFormHandler startFormHandler = processDefinition.getStartFormHandler();
    if (startFormHandler == null) {
      return null;
    }
   
    FormEngine formEngine = Context
      .getProcessEngineConfiguration()
      .getFormEngines()
      .get(formEngineName);
   
    if (formEngine==null) {
      throw new ActivitiException("No formEngine '" + formEngineName +"' defined process engine configuration");
    }
   
    StartFormData startForm = startFormHandler.createStartFormData(processDefinition);
   
    return formEngine.renderStartForm(startForm);
  }
View Full Code Here

Examples of org.activiti.engine.impl.form.StartFormHandler

  }
 
  protected void createStartFormHandlers(BpmnParse bpmnParse, StartEvent startEvent, ProcessDefinitionEntity processDefinition) {
    if (processDefinition.getInitial() != null) {
      if (startEvent.getId().equals(processDefinition.getInitial().getId())) {
        StartFormHandler startFormHandler = new DefaultStartFormHandler();
        startFormHandler.parseConfiguration(startEvent.getFormProperties(), startEvent.getFormKey(), bpmnParse.getDeployment(), processDefinition);
        processDefinition.setStartFormHandler(startFormHandler);
      }
    }
  }
View Full Code Here

Examples of org.activiti.engine.impl.form.StartFormHandler

      .findDeployedProcessDefinitionById(processDefinitionId);
    if (processDefinition == null) {
      throw new ActivitiObjectNotFoundException("No process definition found for id '" + processDefinitionId +"'", ProcessDefinition.class);
    }
   
    StartFormHandler startFormHandler = processDefinition.getStartFormHandler();
    if (startFormHandler == null) {
      throw new ActivitiException("No startFormHandler defined in process '" + processDefinitionId +"'");
    }
   
   
    return startFormHandler.createStartFormData(processDefinition);
  }
View Full Code Here

Examples of org.activiti.engine.impl.form.StartFormHandler

      .getDeploymentManager()
      .findDeployedProcessDefinitionById(processDefinitionId);
    if (processDefinition == null) {
      throw new ActivitiObjectNotFoundException("Process Definition '" + processDefinitionId +"' not found", ProcessDefinition.class);
    }
    StartFormHandler startFormHandler = processDefinition.getStartFormHandler();
    if (startFormHandler == null) {
      return null;
    }
   
    FormEngine formEngine = commandContext
      .getProcessEngineConfiguration()
      .getFormEngines()
      .get(formEngineName);
   
    if (formEngine==null) {
      throw new ActivitiException("No formEngine '" + formEngineName +"' defined process engine configuration");
    }
   
    StartFormData startForm = startFormHandler.createStartFormData(processDefinition);
   
    return formEngine.renderStartForm(startForm);
  }
View Full Code Here

Examples of org.activiti.engine.impl.form.StartFormHandler

    }

    commandContext.getHistoryManager()
      .reportFormPropertiesSubmitted(processInstance, properties, null);
   
    StartFormHandler startFormHandler = processDefinition.getStartFormHandler();
    startFormHandler.submitFormProperties(properties, processInstance);

    processInstance.start();
   
    return processInstance;
  }
View Full Code Here

Examples of org.activiti.engine.impl.form.StartFormHandler

      .findDeployedProcessDefinitionById(processDefinitionId);
    if (processDefinition == null) {
      throw new ActivitiException("No process definition found for id '" + processDefinitionId +"'");
    }
   
    StartFormHandler startFormHandler = processDefinition.getStartFormHandler();
    if (startFormHandler == null) {
      throw new ActivitiException("No startFormHandler defined in process '" + processDefinitionId +"'");
    }
   
   
    return startFormHandler.createStartFormData(processDefinition);
  }
View Full Code Here

Examples of org.camunda.bpm.engine.impl.form.handler.StartFormHandler

    ProcessDefinitionEntity processDefinition = Context
      .getProcessEngineConfiguration()
      .getDeploymentCache()
      .findDeployedProcessDefinitionById(processDefinitionId);
    ensureNotNull("Process Definition '" + processDefinitionId + "' not found", "processDefinition", processDefinition);
    StartFormHandler startFormHandler = processDefinition.getStartFormHandler();
    if (startFormHandler == null) {
      return null;
    }

    FormEngine formEngine = Context
      .getProcessEngineConfiguration()
      .getFormEngines()
      .get(formEngineName);

    ensureNotNull("No formEngine '" + formEngineName + "' defined process engine configuration", "formEngine", formEngine);

    StartFormData startForm = startFormHandler.createStartFormData(processDefinition);

    return formEngine.renderStartForm(startForm);
  }
View Full Code Here

Examples of org.camunda.bpm.engine.impl.form.handler.StartFormHandler

    if(processDefinition.getInitial() != null) {
      for (Element startEventElement : startEventElements) {

        if(startEventElement.attribute("id").equals(processDefinition.getInitial().getId())) {

          StartFormHandler startFormHandler;
          String startFormHandlerClassName = startEventElement.attributeNS(BpmnParser.ACTIVITI_BPMN_EXTENSIONS_NS, "formHandlerClass");
          if (startFormHandlerClassName != null) {
            startFormHandler = (StartFormHandler) ReflectUtil.instantiate(startFormHandlerClassName);
          } else {
            startFormHandler = new DefaultStartFormHandler();
          }
          startFormHandler.parseConfiguration(startEventElement, deployment, processDefinition, this);

          processDefinition.setStartFormHandler(startFormHandler);
        }

      }
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.