diff --git a/spring-beans/src/main/java/org/springframework/beans/BeanUtils.java b/spring-beans/src/main/java/org/springframework/beans/BeanUtils.java index 434827701e4..57157fc0c78 100644 --- a/spring-beans/src/main/java/org/springframework/beans/BeanUtils.java +++ b/spring-beans/src/main/java/org/springframework/beans/BeanUtils.java @@ -54,8 +54,11 @@ import org.springframework.util.StringUtils; * Static convenience methods for JavaBeans: for instantiating beans, * checking bean property types, copying bean properties, etc. * - *

Mainly for use within the framework, but to some degree also - * useful for application classes. + *

Mainly for internal use within the framework, but to some degree also + * useful for application classes. Consider + * Apache Commons BeanUtils, + * BULL - Bean Utils Light Library, + * or similar third-party frameworks for more comprehensive bean utilities. * * @author Rod Johnson * @author Juergen Hoeller @@ -487,7 +490,8 @@ public abstract class BeanUtils { return null; } } - String editorName = targetType.getName() + "Editor"; + String targetTypeName = targetType.getName(); + String editorName = targetTypeName + "Editor"; try { Class editorClass = cl.loadClass(editorName); if (!PropertyEditor.class.isAssignableFrom(editorClass)) { @@ -503,7 +507,7 @@ public abstract class BeanUtils { catch (ClassNotFoundException ex) { if (logger.isDebugEnabled()) { logger.debug("No property editor [" + editorName + "] found for type " + - targetType.getName() + " according to 'Editor' suffix convention"); + targetTypeName + " according to 'Editor' suffix convention"); } unknownEditorTypes.add(targetType); return null; diff --git a/spring-beans/src/main/java/org/springframework/beans/factory/support/ReplaceOverride.java b/spring-beans/src/main/java/org/springframework/beans/factory/support/ReplaceOverride.java index e24dee36750..09b799ad035 100644 --- a/spring-beans/src/main/java/org/springframework/beans/factory/support/ReplaceOverride.java +++ b/spring-beans/src/main/java/org/springframework/beans/factory/support/ReplaceOverride.java @@ -48,7 +48,7 @@ public class ReplaceOverride extends MethodOverride { */ public ReplaceOverride(String methodName, String methodReplacerBeanName) { super(methodName); - Assert.notNull(methodName, "Method replacer bean name must not be null"); + Assert.notNull(methodReplacerBeanName, "Method replacer bean name must not be null"); this.methodReplacerBeanName = methodReplacerBeanName; }