Skip to content

Commit aa7fcb5

Browse files
committed
polishing
1 parent 81e9f6c commit aa7fcb5

File tree

3 files changed

+10
-5
lines changed

3 files changed

+10
-5
lines changed

org.springframework.beans/src/main/java/org/springframework/beans/factory/support/BeanDefinitionReaderUtils.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -168,6 +168,7 @@ public static void registerBeanDefinition(
168168
public static String registerWithGeneratedName(
169169
AbstractBeanDefinition definition, BeanDefinitionRegistry registry)
170170
throws BeanDefinitionStoreException {
171+
171172
String generatedName = generateBeanName(definition, registry, false);
172173
registry.registerBeanDefinition(generatedName, definition);
173174
return generatedName;

org.springframework.core/src/main/java/org/springframework/core/convert/TypeDescriptor.java

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@
2727

2828
/**
2929
* Context about a type to convert from or to.
30+
*
3031
* @author Keith Donald
3132
* @author Andy Clement
3233
* @author Juergen Hoeller
@@ -203,7 +204,7 @@ public static TypeDescriptor nested(Property property, int nestingLevel) {
203204
* @return the type descriptor
204205
*/
205206
public static TypeDescriptor forObject(Object source) {
206-
return source != null ? valueOf(source.getClass()) : null;
207+
return (source != null ? valueOf(source.getClass()) : null);
207208
}
208209

209210
/**
@@ -214,7 +215,7 @@ public static TypeDescriptor forObject(Object source) {
214215
* @see #getObjectType()
215216
*/
216217
public Class<?> getType() {
217-
return type;
218+
return this.type;
218219
}
219220

220221
/**

org.springframework.expression/src/main/java/org/springframework/expression/TypedValue.java

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2002-2010 the original author or authors.
2+
* Copyright 2002-2011 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -31,19 +31,20 @@ public class TypedValue {
3131

3232
public static final TypedValue NULL = new TypedValue(null);
3333

34+
3435
private final Object value;
3536

3637
private TypeDescriptor typeDescriptor;
3738

39+
3840
/**
3941
* Create a TypedValue for a simple object. The type descriptor is inferred
4042
* from the object, so no generic information is preserved.
4143
* @param value the object value
4244
*/
4345
public TypedValue(Object value) {
4446
this.value = value;
45-
// initialized when/if requested
46-
this.typeDescriptor = null;
47+
this.typeDescriptor = null; // initialized when/if requested
4748
}
4849

4950
/**
@@ -56,6 +57,7 @@ public TypedValue(Object value, TypeDescriptor typeDescriptor) {
5657
this.typeDescriptor = typeDescriptor;
5758
}
5859

60+
5961
public Object getValue() {
6062
return this.value;
6163
}
@@ -67,6 +69,7 @@ public TypeDescriptor getTypeDescriptor() {
6769
return this.typeDescriptor;
6870
}
6971

72+
7073
@Override
7174
public String toString() {
7275
StringBuilder str = new StringBuilder();

0 commit comments

Comments
 (0)