package info
This commit is contained in:
parent
522475a05b
commit
cd9f0bc10c
|
|
@ -30,7 +30,7 @@ import org.springframework.model.binder.BindingResult;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* A {@link Binder} implementation that accepts any target object and uses
|
* A {@link Binder} implementation that accepts any target object and uses
|
||||||
* Spring's Expression Language support to evaluate the keys in the field
|
* Spring's Expression Language (SpEL) to evaluate the keys in the field
|
||||||
* value Map.
|
* value Map.
|
||||||
* @author Mark Fisher
|
* @author Mark Fisher
|
||||||
* @since 3.0
|
* @since 3.0
|
||||||
|
|
@ -43,12 +43,11 @@ public class GenericBinder extends AbstractBinder<Object> {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected FieldBinder createFieldBinder(Object model) {
|
protected FieldBinder createFieldBinder(Object model) {
|
||||||
StandardEvaluationContext evaluationContext = new StandardEvaluationContext();
|
StandardEvaluationContext context = new StandardEvaluationContext();
|
||||||
evaluationContext.setRootObject(model);
|
context.setRootObject(model);
|
||||||
return new EvaluationContextFieldBinder(parser, evaluationContext);
|
return new EvaluationContextFieldBinder(parser, context);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
private static class EvaluationContextFieldBinder implements FieldBinder {
|
private static class EvaluationContextFieldBinder implements FieldBinder {
|
||||||
|
|
||||||
private final ExpressionParser parser;
|
private final ExpressionParser parser;
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,5 @@
|
||||||
|
/**
|
||||||
|
* Binder API implementation support.
|
||||||
|
*/
|
||||||
|
package org.springframework.model.binder.support;
|
||||||
|
|
||||||
Loading…
Reference in New Issue