|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.springframework.web.bind.BindUtils
public abstract class BindUtils
Offers convenience methods for binding servlet request parameters to objects, including optional validation.
Constructor Summary | |
---|---|
BindUtils()
|
Method Summary | |
---|---|
static BindException |
bind(ServletRequest request,
Object object,
String objectName)
Bind the parameters from the given request to the given object. |
static BindException |
bind(ServletRequest request,
Object object,
String objectName,
BindInitializer initializer)
Bind the parameters from the given request to the given object, allowing for optional custom editors set in an bind initializer. |
static BindException |
bindAndValidate(ServletRequest request,
Object object,
String objectName,
Validator validator)
Bind the parameters from the given request to the given object, invoking the given validator. |
static BindException |
bindAndValidate(ServletRequest request,
Object object,
String objectName,
Validator validator,
BindInitializer initializer)
Bind the parameters from the given request to the given object, invoking the given validator, and allowing for optional custom editors set in an bind initializer. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public BindUtils()
Method Detail |
---|
public static BindException bind(ServletRequest request, Object object, String objectName)
request
- request containing the parametersobject
- object to bind the parameters toobjectName
- name of the bind object
public static BindException bind(ServletRequest request, Object object, String objectName, BindInitializer initializer) throws ServletException
request
- request containing the parametersobject
- object to bind the parameters toobjectName
- name of the bind objectinitializer
- implementation of the BindInitializer interface
which will be able to set custom editors
ServletException
- if thrown by the BindInitializerpublic static BindException bindAndValidate(ServletRequest request, Object object, String objectName, Validator validator)
request
- request containing the parametersobject
- object to bind the parameters toobjectName
- name of the bind objectvalidator
- validator to be invoked, or null if no validation
public static BindException bindAndValidate(ServletRequest request, Object object, String objectName, Validator validator, BindInitializer initializer) throws ServletException
request
- request containing the parametersobject
- object to bind the parameters toobjectName
- name of the bind objectvalidator
- validator to be invoked, or null if no validationinitializer
- Implementation of the BindInitializer interface which will be able to set custom editors
ServletException
- if thrown by the BindInitializer
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |