@RequestScoped public class DefaultValidator extends AbstractValidator
Constructor and Description |
---|
DefaultValidator(Result result,
ValidationViewsFactory factory,
Outjector outjector,
Proxifier proxifier,
BeanValidator beanValidator,
Localization localization) |
Modifier and Type | Method and Description |
---|---|
void |
add(Message message) |
void |
addAll(java.util.Collection<? extends Message> messages) |
void |
checking(Validations validations) |
java.util.List<Message> |
getErrors() |
boolean |
hasErrors() |
<T extends View> |
onErrorUse(java.lang.Class<T> view) |
void |
validate(java.lang.Object object,
java.lang.Class<?>... groups)
Validate an object using some Bean Validation engine.
|
void |
validateProperties(java.lang.Object object,
java.lang.String... properties)
Validate the specifics propeties of an object using some Bean Validation engine.
|
onErrorForwardTo, onErrorForwardTo, onErrorRedirectTo, onErrorRedirectTo, onErrorSendBadRequest, onErrorUsePageOf, onErrorUsePageOf
public DefaultValidator(Result result, ValidationViewsFactory factory, Outjector outjector, Proxifier proxifier, BeanValidator beanValidator, Localization localization)
public void checking(Validations validations)
public void validate(java.lang.Object object, java.lang.Class<?>... groups)
Validator
object
- The object to be validated.groups
- The groups to be validated.public void validateProperties(java.lang.Object object, java.lang.String... properties)
Validator
object
- The object to be validated.properties
- The names of properties to be validated.public <T extends View> T onErrorUse(java.lang.Class<T> view)
public void addAll(java.util.Collection<? extends Message> messages)
public void add(Message message)
public boolean hasErrors()
public java.util.List<Message> getErrors()
Copyright © 2013 Caelum. All Rights Reserved.