Java org.springframework.validation DataBinder fields, constructors, methods, implement or subclass

Example usage for Java org.springframework.validation DataBinder fields, constructors, methods, implement or subclass

Introduction

In this page you can find the methods, fields and constructors for org.springframework.validation DataBinder.

The text is from its open source code.

Constructor

DataBinder(@Nullable Object target, String objectName)
Create a new DataBinder instance.
DataBinder(@Nullable Object target)
Create a new DataBinder instance, with default object name.

Method

voidaddValidators(Validator... validators)
Add Validators to apply after each binding step.
voidbind(PropertyValues pvs)
Bind the given property values to this binder's target.
Mapclose()
Close this DataBinder, which may result in throwing a BindException if it encountered any errors.
TconvertIfNecessary(@Nullable Object value, @Nullable Class requiredType, @Nullable MethodParameter methodParam)
TconvertIfNecessary(@Nullable Object value, @Nullable Class requiredType, @Nullable Field field)
TconvertIfNecessary(@Nullable Object value, @Nullable Class requiredType, @Nullable TypeDescriptor typeDescriptor)
TconvertIfNecessary(@Nullable Object value, @Nullable Class requiredType)
String[]getAllowedFields()
Return the fields that should be allowed for binding.
BindingResultgetBindingResult()
Return the BindingResult instance created by this DataBinder.
ConversionServicegetConversionService()
Return the associated ConversionService, if any.
StringgetObjectName()
Return the name of the bound object.
ObjectgetTarget()
Return the wrapped target object.
ValidatorgetValidator()
Return the primary Validator to apply after each binding step, if any.
voidinitDirectFieldAccess()
Initialize direct field access for this DataBinder, as alternative to the default bean property access.
voidregisterCustomEditor(Class requiredType, PropertyEditor propertyEditor)
voidregisterCustomEditor(@Nullable Class requiredType, @Nullable String field, PropertyEditor propertyEditor)
voidsetAllowedFields(@Nullable String... allowedFields)
Register fields that should be allowed for binding.
voidsetAutoGrowNestedPaths(boolean autoGrowNestedPaths)
Set whether this binder should attempt to "auto-grow" a nested path that contains a null value.
voidsetConversionService(@Nullable ConversionService conversionService)
Specify a Spring 3.0 ConversionService to use for converting property values, as an alternative to JavaBeans PropertyEditors.
voidsetIgnoreInvalidFields(boolean ignoreInvalidFields)
Set whether to ignore invalid fields, that is, whether to ignore bind parameters that have corresponding fields in the target object which are not accessible (for example because of null values in the nested path).
voidsetIgnoreUnknownFields(boolean ignoreUnknownFields)
Set whether to ignore unknown fields, that is, whether to ignore bind parameters that do not have corresponding fields in the target object.
voidsetMessageCodesResolver(@Nullable MessageCodesResolver messageCodesResolver)
Set the strategy to use for resolving errors into message codes.
voidsetRequiredFields(@Nullable String... requiredFields)
Register fields that are required for each binding process.
voidsetValidator(@Nullable Validator validator)
Set the Validator to apply after each binding step.
voidvalidate()
Invoke the specified Validators, if any.