org.richfaces.validator
Class HibernateValidator
java.lang.Object
org.richfaces.validator.ObjectValidator
org.richfaces.validator.HibernateValidator
public class HibernateValidator
- extends ObjectValidator
Perform validation by Hibernate Validator annotations
- Author:
- asmirnov
|
Method Summary |
protected java.util.ResourceBundle |
createHibernateMessages(javax.faces.context.FacesContext facesContext)
|
protected |
createValidator(javax.faces.context.FacesContext facesContext,
java.lang.Class<? extends java.lang.Object> beanClass)
|
protected |
getValidator(javax.faces.context.FacesContext facesContext,
java.lang.Class<? extends java.lang.Object> beanClass)
Get ( or create ) ClassValidator for a given bean class. |
protected java.util.Collection<java.lang.String> |
validate(javax.faces.context.FacesContext facesContext,
java.lang.Object base,
java.lang.String property,
java.lang.Object value,
java.util.Set<java.lang.String> profiles)
Validate bean property for a new value. |
protected InvalidValue[] |
validateBean(javax.faces.context.FacesContext facesContext,
java.lang.Object base,
java.lang.String property,
java.lang.Object value)
Validate bean property of the base object aganist new value |
protected InvalidValue[] |
validateClass(javax.faces.context.FacesContext facesContext,
java.lang.Class<? extends java.lang.Object> beanClass,
java.lang.String property,
java.lang.Object value)
Validate bean property in the base class aganist new value. |
java.util.Collection<java.lang.String> |
validateGraph(javax.faces.context.FacesContext context,
java.lang.Object value,
java.util.Set<java.lang.String> profiles)
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
validateGraph
public java.util.Collection<java.lang.String> validateGraph(javax.faces.context.FacesContext context,
java.lang.Object value,
java.util.Set<java.lang.String> profiles)
- Specified by:
validateGraph in class ObjectValidator
validateClass
protected InvalidValue[] validateClass(javax.faces.context.FacesContext facesContext,
java.lang.Class<? extends java.lang.Object> beanClass,
java.lang.String property,
java.lang.Object value)
- Validate bean property in the base class aganist new value.
- Parameters:
beanClass - property - value -
- Returns:
getValidator
protected getValidator(javax.faces.context.FacesContext facesContext,
java.lang.Class<? extends java.lang.Object> beanClass)
- Get ( or create )
ClassValidator for a given bean class.
- Parameters:
beanClass -
- Returns:
createValidator
protected createValidator(javax.faces.context.FacesContext facesContext,
java.lang.Class<? extends java.lang.Object> beanClass)
createHibernateMessages
protected java.util.ResourceBundle createHibernateMessages(javax.faces.context.FacesContext facesContext)
- Parameters:
facesContext -
- Returns:
validate
protected java.util.Collection<java.lang.String> validate(javax.faces.context.FacesContext facesContext,
java.lang.Object base,
java.lang.String property,
java.lang.Object value,
java.util.Set<java.lang.String> profiles)
- Description copied from class:
ObjectValidator
- Validate bean property for a new value.
- Specified by:
validate in class ObjectValidator
- Parameters:
facesContext - TODObase - - beanproperty - - bean property name.value - new value.profiles - TODO
- Returns:
- null for a valid value, array of the validation messages
othervise.
validateBean
protected InvalidValue[] validateBean(javax.faces.context.FacesContext facesContext,
java.lang.Object base,
java.lang.String property,
java.lang.Object value)
- Validate bean property of the base object aganist new value
- Parameters:
base - property - value -
- Returns:
Copyright © 2010. All Rights Reserved.