}
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()));
}
}
}