Package org.activiti.validation

Examples of org.activiti.validation.ValidationError


    for (Process process : bpmnModel.getProcesses()) {
      customParseValidator.executeParse(bpmnModel, process);
    }
    for (String errorRef : bpmnModel.getErrors().keySet()) {
      ValidationError error = new ValidationError();
      error.setValidatorSetName("Manual BPMN parse validator");
      error.setProblem(errorRef);
      error.setActivityId(bpmnModel.getErrors().get(errorRef));
      errorList.add(error);
    }
    return errorList;
  }
View Full Code Here


  protected void addWarning(List<ValidationError> validationErrors, String problem, Process process, BaseElement baseElement, String description) {
    addError(validationErrors, problem, process, baseElement, description, true);
  }
 
  protected void addError(List<ValidationError> validationErrors, String problem, Process process, BaseElement baseElement, String description, boolean isWarning) {
    ValidationError error = new ValidationError();
    error.setWarning(isWarning);
   
    if (process != null) {
      error.setProcessDefinitionId(process.getId());
      error.setProcessDefinitionName(process.getName());
    }
   
    if (baseElement != null) {
      error.setXmlLineNumber(baseElement.getXmlRowNumber());
      error.setXmlColumnNumber(baseElement.getXmlColumnNumber());
    }
    error.setProblem(problem);
    error.setDefaultDescription(description);
   
    if (baseElement instanceof FlowElement) {
      FlowElement flowElement = (FlowElement) baseElement;
      error.setActivityId(flowElement.getId());
      error.setActivityName(flowElement.getName());
    }
   
    addError(validationErrors, error);
  }
View Full Code Here

   
    addError(validationErrors, error);
  }
 
  protected void addError(List<ValidationError> validationErrors, String problem, Process process, String id, String description) {
    ValidationError error = new ValidationError();
   
    if (process != null) {
      error.setProcessDefinitionId(process.getId());
      error.setProcessDefinitionName(process.getName());
    }
   
    error.setProblem(problem);
    error.setDefaultDescription(description);
    error.setActivityId(id);
   
    addError(validationErrors, error);
  }
View Full Code Here

TOP

Related Classes of org.activiti.validation.ValidationError

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.