Skip to content

Commit 9f1e822

Browse files
committed
Polishing
1 parent b4baa86 commit 9f1e822

File tree

4 files changed

+15
-10
lines changed

4 files changed

+15
-10
lines changed

settings.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@ include "spring-aop"
1010
include "spring-aspects"
1111
include "spring-beans"
1212
include "spring-context"
13-
include "spring-context-support"
1413
include "spring-context-indexer"
14+
include "spring-context-support"
1515
include "spring-core"
1616
include "kotlin-coroutines"
1717
project(':kotlin-coroutines').projectDir = file('spring-core/kotlin-coroutines')
@@ -26,8 +26,8 @@ include "spring-oxm"
2626
include "spring-test"
2727
include "spring-tx"
2828
include "spring-web"
29-
include "spring-webmvc"
3029
include "spring-webflux"
30+
include "spring-webmvc"
3131
include "spring-websocket"
3232
include "framework-bom"
3333
include "integration-tests"

spring-beans/src/main/java/org/springframework/beans/TypeMismatchException.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2002-2018 the original author or authors.
2+
* Copyright 2002-2021 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.
@@ -41,10 +41,10 @@ public class TypeMismatchException extends PropertyAccessException {
4141
private String propertyName;
4242

4343
@Nullable
44-
private transient Object value;
44+
private final transient Object value;
4545

4646
@Nullable
47-
private Class<?> requiredType;
47+
private final Class<?> requiredType;
4848

4949

5050
/**

spring-context/src/main/java/org/springframework/validation/beanvalidation/SpringValidatorAdapter.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2002-2020 the original author or authors.
2+
* Copyright 2002-2021 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.
@@ -179,7 +179,7 @@ protected void processConstraintViolations(Set<ConstraintViolation<Object>> viol
179179
}
180180
}
181181
else {
182-
// got no BindingResult - can only do standard rejectValue call
182+
// Got no BindingResult - can only do standard rejectValue call
183183
// with automatic extraction of the current field value
184184
errors.rejectValue(field, errorCode, errorArgs, violation.getMessage());
185185
}
@@ -386,7 +386,7 @@ public <T> T unwrap(@Nullable Class<T> type) {
386386
return (type != null ? this.targetValidator.unwrap(type) : (T) this.targetValidator);
387387
}
388388
catch (ValidationException ex) {
389-
// ignore if just being asked for plain Validator
389+
// Ignore if just being asked for plain JSR-303 Validator
390390
if (javax.validation.Validator.class == type) {
391391
return (T) this.targetValidator;
392392
}

spring-context/src/test/java/org/springframework/context/annotation/EnableLoadTimeWeavingTests.java

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2002-2019 the original author or authors.
2+
* Copyright 2002-2021 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.
@@ -40,7 +40,7 @@ public class EnableLoadTimeWeavingTests {
4040
@Test
4141
public void control() {
4242
GenericXmlApplicationContext ctx =
43-
new GenericXmlApplicationContext(getClass(), "EnableLoadTimeWeavingTests-context.xml");
43+
new GenericXmlApplicationContext(getClass(), "EnableLoadTimeWeavingTests-context.xml");
4444
ctx.getBean("loadTimeWeaver", LoadTimeWeaver.class);
4545
}
4646

@@ -73,9 +73,11 @@ public void enableLTW_withAjWeavingEnabled() {
7373
verify(loadTimeWeaver).addTransformer(isA(ClassFileTransformer.class));
7474
}
7575

76+
7677
@Configuration
7778
@EnableLoadTimeWeaving(aspectjWeaving=AspectJWeaving.DISABLED)
7879
static class EnableLTWConfig_withAjWeavingDisabled implements LoadTimeWeavingConfigurer {
80+
7981
@Override
8082
public LoadTimeWeaver getLoadTimeWeaver() {
8183
return mock(LoadTimeWeaver.class);
@@ -85,6 +87,7 @@ public LoadTimeWeaver getLoadTimeWeaver() {
8587
@Configuration
8688
@EnableLoadTimeWeaving(aspectjWeaving=AspectJWeaving.AUTODETECT)
8789
static class EnableLTWConfig_withAjWeavingAutodetect implements LoadTimeWeavingConfigurer {
90+
8891
@Override
8992
public LoadTimeWeaver getLoadTimeWeaver() {
9093
return mock(LoadTimeWeaver.class);
@@ -94,9 +97,11 @@ public LoadTimeWeaver getLoadTimeWeaver() {
9497
@Configuration
9598
@EnableLoadTimeWeaving(aspectjWeaving=AspectJWeaving.ENABLED)
9699
static class EnableLTWConfig_withAjWeavingEnabled implements LoadTimeWeavingConfigurer {
100+
97101
@Override
98102
public LoadTimeWeaver getLoadTimeWeaver() {
99103
return mock(LoadTimeWeaver.class);
100104
}
101105
}
106+
102107
}

0 commit comments

Comments
 (0)