Class ExtendedServletRequestDataBinder
- java.lang.Object
- org.springframework.validation.DataBinder
- org.springframework.web.bind.WebDataBinder
- org.springframework.web.bind.ServletRequestDataBinder
- org.springframework.web.servlet.mvc.method.annotation.ExtendedServletRequestDataBinder
- All Implemented Interfaces:
PropertyEditorRegistry
,TypeConverter
public class ExtendedServletRequestDataBinder extends ServletRequestDataBinder
Subclass ofServletRequestDataBinder
that adds URI template variables to the values used for data binding.- Since:
- 3.1
- Author:
- Rossen Stoyanchev
Field Summary
Fields inherited from class org.springframework.web.bind.WebDataBinder
DEFAULT_FIELD_DEFAULT_PREFIX, DEFAULT_FIELD_MARKER_PREFIX
Fields inherited from class org.springframework.validation.DataBinder
DEFAULT_AUTO_GROW_COLLECTION_LIMIT, DEFAULT_OBJECT_NAME, logger
Constructor Summary
Constructors Constructor Description ExtendedServletRequestDataBinder(Object target)
Create a new instance, with default object name.ExtendedServletRequestDataBinder(Object target, String objectName)
Create a new instance.
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
addBindValues(MutablePropertyValues mpvs, ServletRequest request)
Merge URI variables into the property values to use for data binding.Methods inherited from class org.springframework.web.bind.ServletRequestDataBinder
bind, closeNoCatch
Methods inherited from class org.springframework.web.bind.WebDataBinder
bindMultipart, checkFieldDefaults, checkFieldMarkers, doBind, getEmptyValue, getFieldDefaultPrefix, getFieldMarkerPrefix, isBindEmptyMultipartFiles, setBindEmptyMultipartFiles, setFieldDefaultPrefix, setFieldMarkerPrefix
Methods inherited from class org.springframework.validation.DataBinder
addCustomFormatter, addCustomFormatter, addCustomFormatter, addValidators, applyPropertyValues, bind, checkAllowedFields, checkRequiredFields, close, convertIfNecessary, convertIfNecessary, convertIfNecessary, createBeanPropertyBindingResult, createDirectFieldBindingResult, findCustomEditor, getAllowedFields, getAutoGrowCollectionLimit, getBindingErrorProcessor, getBindingResult, getConversionService, getDisallowedFields, getInternalBindingResult, getObjectName, getPropertyAccessor, getPropertyEditorRegistry, getRequiredFields, getSimpleTypeConverter, getTarget, getTypeConverter, getValidator, getValidators, initBeanPropertyAccess, initDirectFieldAccess, isAllowed, isAutoGrowNestedPaths, isIgnoreInvalidFields, isIgnoreUnknownFields, registerCustomEditor, registerCustomEditor, replaceValidators, setAllowedFields, setAutoGrowCollectionLimit, setAutoGrowNestedPaths, setBindingErrorProcessor, setConversionService, setDisallowedFields, setExtractOldValueForEditor, setIgnoreInvalidFields, setIgnoreUnknownFields, setMessageCodesResolver, setRequiredFields, setValidator, validate, validate
Constructor Detail
ExtendedServletRequestDataBinder
public ExtendedServletRequestDataBinder(Object target)
Create a new instance, with default object name.- Parameters:
target
- the target object to bind onto (ornull
if the binder is just used to convert a plain parameter value)- See Also:
DataBinder.DEFAULT_OBJECT_NAME
ExtendedServletRequestDataBinder
public ExtendedServletRequestDataBinder(Object target, String objectName)
Create a new instance.- Parameters:
target
- the target object to bind onto (ornull
if the binder is just used to convert a plain parameter value)objectName
- the name of the target object- See Also:
DataBinder.DEFAULT_OBJECT_NAME
Method Detail
addBindValues
protected void addBindValues(MutablePropertyValues mpvs, ServletRequest request)
Merge URI variables into the property values to use for data binding.- Overrides:
addBindValues
in classServletRequestDataBinder
- Parameters:
mpvs
- the property values that will be used for data bindingrequest
- the current request