Package io.avaje.http.api
Interface Validator
-
public interface Validator
Validator for form beans or request beans.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
validate(Object bean)
Validate the bean throwing an exception if the bean fails validation.
-
-
-
Method Detail
-
validate
void validate(Object bean)
Validate the bean throwing an exception if the bean fails validation.Typically the exception will be handled by a specific exception handler returning a 422 or 400 status code and usually a map of field paths to error messages.
- Parameters:
bean
- The bean to validate
-
-