Class GroupValidator
- java.lang.Object
-
- org.uberfire.ext.security.management.api.validation.GroupValidator
-
- All Implemented Interfaces:
EntityValidator<org.jboss.errai.security.shared.api.Group>
public abstract class GroupValidator extends Object implements EntityValidator<org.jboss.errai.security.shared.api.Group>
The base validator class for a Group entity based on JSR303 Bean Validations.
Current validations:
- Group name is mandatory
This provides validation logic for both backend and client sides, but you have to provide an instantiable class that provides the error message descriptions for each validation error supported.
- Since:
- 0.8.0
-
-
Field Summary
Fields Modifier and Type Field Description static StringKEY_NAME_NOT_EMPTY
-
Constructor Summary
Constructors Constructor Description GroupValidator()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description abstract StringgetMessage(String key)Set<javax.validation.ConstraintViolation<org.jboss.errai.security.shared.api.Group>>validate(org.jboss.errai.security.shared.api.Group entity)Validates the given entity.
-
-
-
Field Detail
-
KEY_NAME_NOT_EMPTY
public static final String KEY_NAME_NOT_EMPTY
- See Also:
- Constant Field Values
-
-
Method Detail
-
validate
public Set<javax.validation.ConstraintViolation<org.jboss.errai.security.shared.api.Group>> validate(org.jboss.errai.security.shared.api.Group entity)
Description copied from interface:EntityValidatorValidates the given entity.
- Specified by:
validatein interfaceEntityValidator<org.jboss.errai.security.shared.api.Group>- Parameters:
entity- The entity instance to validate.- Returns:
- The validation constraints collection produced.
-
-