Skip to content

Commit 70f2736

Browse files
committed
Polishing
(cherry picked from commit b344c92)
1 parent a5070d5 commit 70f2736

File tree

4 files changed

+24
-21
lines changed

4 files changed

+24
-21
lines changed

spring-beans/src/main/java/org/springframework/beans/factory/BeanFactory.java

Lines changed: 14 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -66,24 +66,27 @@
6666
* 1. BeanNameAware's {@code setBeanName}<br>
6767
* 2. BeanClassLoaderAware's {@code setBeanClassLoader}<br>
6868
* 3. BeanFactoryAware's {@code setBeanFactory}<br>
69-
* 4. ResourceLoaderAware's {@code setResourceLoader}
69+
* 4. EnvironmentAware's {@code setEnvironment}
70+
* 5. EmbeddedValueResolverAware's {@code setEmbeddedValueResolver}
71+
* 6. ResourceLoaderAware's {@code setResourceLoader}
7072
* (only applicable when running in an application context)<br>
71-
* 5. ApplicationEventPublisherAware's {@code setApplicationEventPublisher}
73+
* 7. ApplicationEventPublisherAware's {@code setApplicationEventPublisher}
7274
* (only applicable when running in an application context)<br>
73-
* 6. MessageSourceAware's {@code setMessageSource}
75+
* 8. MessageSourceAware's {@code setMessageSource}
7476
* (only applicable when running in an application context)<br>
75-
* 7. ApplicationContextAware's {@code setApplicationContext}
77+
* 9. ApplicationContextAware's {@code setApplicationContext}
7678
* (only applicable when running in an application context)<br>
77-
* 8. ServletContextAware's {@code setServletContext}
79+
* 10. ServletContextAware's {@code setServletContext}
7880
* (only applicable when running in a web application context)<br>
79-
* 9. {@code postProcessBeforeInitialization} methods of BeanPostProcessors<br>
80-
* 10. InitializingBean's {@code afterPropertiesSet}<br>
81-
* 11. a custom init-method definition<br>
82-
* 12. {@code postProcessAfterInitialization} methods of BeanPostProcessors
81+
* 11. {@code postProcessBeforeInitialization} methods of BeanPostProcessors<br>
82+
* 12. InitializingBean's {@code afterPropertiesSet}<br>
83+
* 13. a custom init-method definition<br>
84+
* 14. {@code postProcessAfterInitialization} methods of BeanPostProcessors
8385
*
8486
* <p>On shutdown of a bean factory, the following lifecycle methods apply:<br>
85-
* 1. DisposableBean's {@code destroy}<br>
86-
* 2. a custom destroy-method definition
87+
* 1. {@code postProcessBeforeDestruction} methods of DestructionAwareBeanPostProcessors
88+
* 2. DisposableBean's {@code destroy}<br>
89+
* 3. a custom destroy-method definition
8790
*
8891
* @author Rod Johnson
8992
* @author Juergen Hoeller

spring-context/src/main/java/org/springframework/format/datetime/DateFormatter.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2002-2013 the original author or authors.
2+
* Copyright 2002-2016 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.
@@ -189,7 +189,7 @@ private DateFormat createDateFormat(Locale locale) {
189189
if (timeStyle != -1) {
190190
return DateFormat.getTimeInstance(timeStyle, locale);
191191
}
192-
throw new IllegalStateException("Unsupported style pattern '"+ this.stylePattern+ "'");
192+
throw new IllegalStateException("Unsupported style pattern '" + this.stylePattern + "'");
193193

194194
}
195195
return DateFormat.getDateInstance(this.style, locale);

spring-expression/src/main/java/org/springframework/expression/spel/support/ReflectionHelper.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2002-2015 the original author or authors.
2+
* Copyright 2002-2016 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.
@@ -219,7 +219,7 @@ else if (typeConverter.canConvert(suppliedArg, expectedArg)) {
219219
// or more other arguments left to pass to it.
220220
Class<?> varargsParamType = expectedArgTypes.get(expectedArgTypes.size() - 1).getElementTypeDescriptor().getType();
221221

222-
// All remaining parameters must be of this type or convertable to this type
222+
// All remaining parameters must be of this type or convertible to this type
223223
for (int i = expectedArgTypes.size() - 1; i < suppliedArgTypes.size(); i++) {
224224
TypeDescriptor suppliedArg = suppliedArgTypes.get(i);
225225
if (suppliedArg == null) {

spring-tx/src/main/java/org/springframework/dao/support/DataAccessUtils.java

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2002-2012 the original author or authors.
2+
* Copyright 2002-2016 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.
@@ -122,7 +122,7 @@ public static <T> T requiredUniqueResult(Collection<T> results) throws Incorrect
122122
/**
123123
* Return a unique result object from the given Collection.
124124
* Throws an exception if 0 or more than 1 result objects found,
125-
* of if the unique result object is not convertable to the
125+
* of if the unique result object is not convertible to the
126126
* specified required type.
127127
* @param results the result Collection (can be {@code null})
128128
* @return the unique result object
@@ -162,15 +162,15 @@ else if (Number.class.isAssignableFrom(requiredType) && Number.class.isInstance(
162162
/**
163163
* Return a unique int result from the given Collection.
164164
* Throws an exception if 0 or more than 1 result objects found,
165-
* of if the unique result object is not convertable to an int.
165+
* of if the unique result object is not convertible to an int.
166166
* @param results the result Collection (can be {@code null})
167167
* @return the unique int result
168168
* @throws IncorrectResultSizeDataAccessException if more than one
169169
* result object has been found in the given Collection
170170
* @throws EmptyResultDataAccessException if no result object
171171
* at all has been found in the given Collection
172172
* @throws TypeMismatchDataAccessException if the unique object
173-
* in the collection is not convertable to an int
173+
* in the collection is not convertible to an int
174174
*/
175175
public static int intResult(Collection results)
176176
throws IncorrectResultSizeDataAccessException, TypeMismatchDataAccessException {
@@ -181,15 +181,15 @@ public static int intResult(Collection results)
181181
/**
182182
* Return a unique long result from the given Collection.
183183
* Throws an exception if 0 or more than 1 result objects found,
184-
* of if the unique result object is not convertable to a long.
184+
* of if the unique result object is not convertible to a long.
185185
* @param results the result Collection (can be {@code null})
186186
* @return the unique long result
187187
* @throws IncorrectResultSizeDataAccessException if more than one
188188
* result object has been found in the given Collection
189189
* @throws EmptyResultDataAccessException if no result object
190190
* at all has been found in the given Collection
191191
* @throws TypeMismatchDataAccessException if the unique object
192-
* in the collection is not convertable to a long
192+
* in the collection is not convertible to a long
193193
*/
194194
public static long longResult(Collection results)
195195
throws IncorrectResultSizeDataAccessException, TypeMismatchDataAccessException {

0 commit comments

Comments
 (0)