提交 641bc35a 编写于 作者: J Juergen Hoeller

fixed setRootObject check in StandardEvaluationContext (SPR-8241)

上级 c166803d
/*
* Copyright 2002-2009 the original author or authors.
* Copyright 2002-2011 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
......@@ -80,18 +80,14 @@ public class StandardEvaluationContext implements EvaluationContext {
}
public void setRootObject(Object rootObject) {
if (this.rootObject == null) {
this.rootObject = TypedValue.NULL;
} else {
this.rootObject = new TypedValue(rootObject);//, TypeDescriptor.forObject(rootObject));
}
}
public void setRootObject(Object rootObject, TypeDescriptor typeDescriptor) {
this.rootObject = new TypedValue(rootObject, typeDescriptor);
}
public void setRootObject(Object rootObject) {
this.rootObject = (rootObject != null ? new TypedValue(rootObject) : TypedValue.NULL);
}
public TypedValue getRootObject() {
return this.rootObject;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册