public void validate(final ValidationRules validationRules, final ValidationPhase validationPhase, final Map<String, Object[]> params, final Object form, final ActionErrors errors) { final Collection<ValidationRule> phaseValidationRules = validationRules .getPhaseValidationRules(validationPhase); if (validationRules != null) { for (final ValidationRule validationRule : phaseValidationRules) { validationRule.apply(params, form, errors); } if (!errors.isEmpty()) { throw new ValidationException(); } } }
validationRules != null と判定するのではなく phaseValidationRules で判定するべき