类 MapBindingResult
- java.lang.Object
- org.springframework.validation.AbstractErrors
- org.springframework.validation.AbstractBindingResult
- org.springframework.validation.MapBindingResult
- 所有已实现的接口:
Serializable
,BindingResult
,Errors
public class MapBindingResult extends AbstractBindingResult implements Serializable
Map-based implementation of the BindingResult interface, supporting registration and evaluation of binding errors on Map attributes.Can be used as errors holder for custom binding onto a Map, for example when invoking a Validator for a Map object.
字段概要
从接口继承的字段 org.springframework.validation.BindingResult
MODEL_KEY_PREFIX
从接口继承的字段 org.springframework.validation.Errors
NESTED_PATH_SEPARATOR
构造器概要
构造器 构造器 说明 MapBindingResult(Map<?,?> target, String objectName)
Create a new MapBindingResult instance.
方法概要
所有方法 实例方法 具体方法 修饰符和类型 方法 说明 protected Object
getActualFieldValue(String field)
Extract the actual field value for the given field.Object
getTarget()
Return the wrapped target object.Map<?,?>
getTargetMap()
从类继承的方法 org.springframework.validation.AbstractBindingResult
addAllErrors, addError, equals, findEditor, formatFieldValue, getAllErrors, getErrorCount, getFieldError, getFieldError, getFieldErrors, getFieldErrors, getFieldType, getFieldValue, getGlobalError, getGlobalErrors, getMessageCodesResolver, getModel, getObjectName, getPropertyEditorRegistry, getRawFieldValue, getSuppressedFields, hasErrors, hashCode, recordSuppressedField, reject, rejectValue, resolveMessageCodes, resolveMessageCodes, setMessageCodesResolver
从类继承的方法 org.springframework.validation.AbstractErrors
canonicalFieldName, doSetNestedPath, fixedField, getFieldErrorCount, getFieldErrorCount, getGlobalErrorCount, getNestedPath, hasFieldErrors, hasFieldErrors, hasGlobalErrors, isMatchingFieldError, popNestedPath, pushNestedPath, reject, reject, rejectValue, rejectValue, setNestedPath, toString
从接口继承的方法 org.springframework.validation.Errors
getFieldErrorCount, getFieldErrorCount, getGlobalErrorCount, getNestedPath, hasFieldErrors, hasFieldErrors, hasGlobalErrors, popNestedPath, pushNestedPath, reject, reject, rejectValue, rejectValue, setNestedPath
构造器详细资料
MapBindingResult
public MapBindingResult(Map<?,?> target, String objectName)
Create a new MapBindingResult instance.- 参数:
target
- the target Map to bind ontoobjectName
- the name of the target object
方法详细资料
getTargetMap
public final Map<?,?> getTargetMap()
getTarget
public final Object getTarget()
从类复制的说明:AbstractBindingResult
Return the wrapped target object.- 指定者:
getTarget
在接口中BindingResult
- 指定者:
getTarget
在类中AbstractBindingResult
getActualFieldValue
protected Object getActualFieldValue(String field)
从类复制的说明:AbstractBindingResult
Extract the actual field value for the given field.- 指定者:
getActualFieldValue
在类中AbstractBindingResult
- 参数:
field
- the field to check- 返回:
- the current value of the field