Sha256: 5769520671a0008387bbb518097f8df0c9c0dd18737993748191891259142f0f
Contents?: true
Size: 566 Bytes
Versions: 155
Compression:
Stored size: 566 Bytes
Contents
package org.embulk.config; import java.util.Set; import javax.validation.Validator; import javax.validation.ConstraintViolation; public class TaskValidator { private final Validator validator; public TaskValidator(Validator validator) { this.validator = validator; } public <T> void validateModel(T model) throws TaskValidationException { Set<ConstraintViolation<T>> violations = validator.validate(model); if (!violations.isEmpty()) { throw new TaskValidationException(violations); } } }
Version data entries
155 entries across 155 versions & 1 rubygems