Browse Source

Make inner classes static where possible

Closes gh-22804
pull/22816/head
Сергей Цыпанов 6 years ago committed by Sam Brannen
parent
commit
18af3892dd
  1. 2
      spring-aop/src/main/java/org/springframework/aop/aspectj/annotation/InstantiationModelAwarePointcutAdvisorImpl.java
  2. 2
      spring-context/src/main/java/org/springframework/context/annotation/CommonAnnotationBeanPostProcessor.java
  3. 2
      spring-core/src/main/java/org/springframework/core/convert/support/IntegerToEnumConverterFactory.java
  4. 2
      spring-core/src/main/java/org/springframework/core/convert/support/StringToEnumConverterFactory.java
  5. 2
      spring-tx/src/main/java/org/springframework/transaction/interceptor/TransactionAspectSupport.java

2
spring-aop/src/main/java/org/springframework/aop/aspectj/annotation/InstantiationModelAwarePointcutAdvisorImpl.java

@ -263,7 +263,7 @@ final class InstantiationModelAwarePointcutAdvisorImpl @@ -263,7 +263,7 @@ final class InstantiationModelAwarePointcutAdvisorImpl
* Note that this is a <i>dynamic</i> pointcut; otherwise it might be optimized out
* if it does not at first match statically.
*/
private final class PerTargetInstantiationModelPointcut extends DynamicMethodMatcherPointcut {
private static final class PerTargetInstantiationModelPointcut extends DynamicMethodMatcherPointcut {
private final AspectJExpressionPointcut declaredPointcut;

2
spring-context/src/main/java/org/springframework/context/annotation/CommonAnnotationBeanPostProcessor.java

@ -565,7 +565,7 @@ public class CommonAnnotationBeanPostProcessor extends InitDestroyAnnotationBean @@ -565,7 +565,7 @@ public class CommonAnnotationBeanPostProcessor extends InitDestroyAnnotationBean
* Class representing generic injection information about an annotated field
* or setter method, supporting @Resource and related annotations.
*/
protected abstract class LookupElement extends InjectionMetadata.InjectedElement {
protected abstract static class LookupElement extends InjectionMetadata.InjectedElement {
protected String name = "";

2
spring-core/src/main/java/org/springframework/core/convert/support/IntegerToEnumConverterFactory.java

@ -35,7 +35,7 @@ final class IntegerToEnumConverterFactory implements ConverterFactory<Integer, E @@ -35,7 +35,7 @@ final class IntegerToEnumConverterFactory implements ConverterFactory<Integer, E
}
private class IntegerToEnum<T extends Enum> implements Converter<Integer, T> {
private static class IntegerToEnum<T extends Enum> implements Converter<Integer, T> {
private final Class<T> enumType;

2
spring-core/src/main/java/org/springframework/core/convert/support/StringToEnumConverterFactory.java

@ -35,7 +35,7 @@ final class StringToEnumConverterFactory implements ConverterFactory<String, Enu @@ -35,7 +35,7 @@ final class StringToEnumConverterFactory implements ConverterFactory<String, Enu
}
private class StringToEnum<T extends Enum> implements Converter<String, T> {
private static class StringToEnum<T extends Enum> implements Converter<String, T> {
private final Class<T> enumType;

2
spring-tx/src/main/java/org/springframework/transaction/interceptor/TransactionAspectSupport.java

@ -617,7 +617,7 @@ public abstract class TransactionAspectSupport implements BeanFactoryAware, Init @@ -617,7 +617,7 @@ public abstract class TransactionAspectSupport implements BeanFactoryAware, Init
* Opaque object used to hold Transaction information. Subclasses
* must pass it back to methods on this class, but not see its internals.
*/
protected final class TransactionInfo {
protected static final class TransactionInfo {
@Nullable
private final PlatformTransactionManager transactionManager;

Loading…
Cancel
Save