Search in sources :

Example 1 with ProcessValidatorImpl

use of org.activiti.validation.ProcessValidatorImpl in project Activiti by Activiti.

the class ProcessEngineAutoConfiguration method addAsyncPropertyValidator.

protected void addAsyncPropertyValidator(ActivitiProperties activitiProperties, SpringProcessEngineConfiguration conf) {
    if (!activitiProperties.isAsyncExecutorActivate()) {
        ValidatorSet springBootStarterValidatorSet = new ValidatorSet("activiti-spring-boot-starter");
        springBootStarterValidatorSet.addValidator(new AsyncPropertyValidator());
        if (conf.getProcessValidator() == null) {
            ProcessValidatorImpl processValidator = new ProcessValidatorImpl();
            processValidator.addValidatorSet(springBootStarterValidatorSet);
            conf.setProcessValidator(processValidator);
        } else {
            conf.getProcessValidator().getValidatorSets().add(springBootStarterValidatorSet);
        }
    }
}
Also used : ProcessValidatorImpl(org.activiti.validation.ProcessValidatorImpl) ValidatorSet(org.activiti.validation.validator.ValidatorSet) AsyncPropertyValidator(org.activiti.spring.boot.process.validation.AsyncPropertyValidator)

Aggregations

AsyncPropertyValidator (org.activiti.spring.boot.process.validation.AsyncPropertyValidator)1 ProcessValidatorImpl (org.activiti.validation.ProcessValidatorImpl)1 ValidatorSet (org.activiti.validation.validator.ValidatorSet)1