Search in sources :

Example 1 with ValidationException

use of com.recurly.v3.exception.ValidationException in project front50 by spinnaker.

the class ApplicationService method validate.

private void validate(Application application) {
    ApplicationValidationErrors errors = new ApplicationValidationErrors(application);
    validators.forEach(v -> v.validate(application, errors));
    if (errors.hasErrors()) {
        throw new ValidationException(errors);
    }
}
Also used : ValidationException(com.netflix.spinnaker.front50.exception.ValidationException) ApplicationValidationErrors(com.netflix.spinnaker.front50.validator.ApplicationValidationErrors)

Aggregations

ValidationException (com.netflix.spinnaker.front50.exception.ValidationException)1 ApplicationValidationErrors (com.netflix.spinnaker.front50.validator.ApplicationValidationErrors)1