Package org.drools.process.core.validation.impl

Examples of org.drools.process.core.validation.impl.ProcessValidationErrorImpl


    }
   
    private void validateTimer(final Timer timer, final Node node,
        final RuleFlowProcess process, final List<ProcessValidationError> errors) {
      if (timer.getDelay() == null) {
        errors.add(new ProcessValidationErrorImpl(process,
                "Node '" + node.getName() + "' [" + node.getId() + "] has timer with no delay specified."));
      } else {
        try {
          TimeUtils.parseTimeString(timer.getDelay());
        } catch (RuntimeDroolsException e) {
          errors.add(new ProcessValidationErrorImpl(process,
                    "Could not parse delay '" + timer.getDelay() + "' of node '" + node.getName() + "': " + e.getMessage()));
        }
      }
      if (timer.getPeriod() != null) {
        try {
          TimeUtils.parseTimeString(timer.getPeriod());
        } catch (RuntimeDroolsException e) {
          errors.add(new ProcessValidationErrorImpl(process,
                    "Could not parse period '" + timer.getPeriod() + "' of node '" + node.getName() + "': " + e.getMessage()));
        }
      }
    }
View Full Code Here

TOP

Related Classes of org.drools.process.core.validation.impl.ProcessValidationErrorImpl

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.