fr.paris.lutece.portal.web.xpages
Class AbstractXPageApplication

java.lang.Object
  extended by fr.paris.lutece.portal.web.xpages.AbstractXPageApplication
All Implemented Interfaces:
XPageApplication, Serializable

public abstract class AbstractXPageApplication
extends Object
implements XPageApplication

Abstract XPageApplication provides

See Also:
Serialized Form

Constructor Summary
AbstractXPageApplication()
           
 
Method Summary
protected  void populate(Object bean, javax.servlet.http.HttpServletRequest request)
          Populate a bean using parameters in http request
protected
<T> Set<javax.validation.ConstraintViolation<T>>
validate(T bean)
          Validates a bean.
protected
<T> List<ValidationError>
validate(T bean, String strFieldsKeyPrefix, Locale locale)
          Validates a bean
protected
<T> List<ValidationError>
validate(T bean, ValidationErrorConfig config, Locale locale)
          Validates a bean
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface fr.paris.lutece.portal.web.xpages.XPageApplication
getPage
 

Constructor Detail

AbstractXPageApplication

public AbstractXPageApplication()
Method Detail

populate

protected void populate(Object bean,
                        javax.servlet.http.HttpServletRequest request)
Populate a bean using parameters in http request

Parameters:
bean - bean to populate
request - http request

validate

protected <T> Set<javax.validation.ConstraintViolation<T>> validate(T bean)
Validates a bean.

Type Parameters:
T - the bean type
Parameters:
bean - the bean to validate
Returns:
the sets of constraints that has been violated

validate

protected <T> List<ValidationError> validate(T bean,
                                             String strFieldsKeyPrefix,
                                             Locale locale)
Validates a bean

Type Parameters:
T - The bean type
Parameters:
bean - The bean to validate
strFieldsKeyPrefix - The fields keys prefix in resources files
locale - The locale
Returns:
The error list

validate

protected <T> List<ValidationError> validate(T bean,
                                             ValidationErrorConfig config,
                                             Locale locale)
Validates a bean

Type Parameters:
T - The bean type
Parameters:
bean - The bean to validate
config - The config for Error validation rendering
locale - The locale
Returns:
The error list


Copyright © 2014 Mairie de Paris. All Rights Reserved.