File tree Expand file tree Collapse file tree 4 files changed +20
-7
lines changed
spring-core/src/main/java/org/springframework/core Expand file tree Collapse file tree 4 files changed +20
-7
lines changed Original file line number Diff line number Diff line change 1
1
/*
2
- * Copyright 2002-2021 the original author or authors.
2
+ * Copyright 2002-2022 the original author or authors.
3
3
*
4
4
* Licensed under the Apache License, Version 2.0 (the "License");
5
5
* you may not use this file except in compliance with the License.
18
18
19
19
/**
20
20
* Default implementation of the {@link ParameterNameDiscoverer} strategy interface,
21
- * using the Java 8 standard reflection mechanism (if available) , and falling back
22
- * to the ASM-based {@link LocalVariableTableParameterNameDiscoverer} for checking
23
- * debug information in the class file.
21
+ * using the Java 8 standard reflection mechanism, and falling back to the ASM-based
22
+ * {@link LocalVariableTableParameterNameDiscoverer} for checking debug information
23
+ * in the class file (e.g. for classes compiled with earlier Java versions) .
24
24
*
25
25
* <p>If a Kotlin reflection implementation is present,
26
26
* {@link KotlinReflectionParameterNameDiscoverer} is added first in the list and
Original file line number Diff line number Diff line change 1
1
/*
2
- * Copyright 2002-2017 the original author or authors.
2
+ * Copyright 2002-2022 the original author or authors.
3
3
*
4
4
* Licensed under the Apache License, Version 2.0 (the "License");
5
5
* you may not use this file except in compliance with the License.
31
31
* {@link ParameterNameDiscoverer} implementation which uses Kotlin's reflection facilities
32
32
* for introspecting parameter names.
33
33
*
34
- * Compared to {@link StandardReflectionParameterNameDiscoverer}, it allows in addition to
34
+ * <p> Compared to {@link StandardReflectionParameterNameDiscoverer}, it allows in addition to
35
35
* determine interface parameter names without requiring Java 8 -parameters compiler flag.
36
36
*
37
37
* @author Sebastien Deleuze
38
38
* @since 5.0
39
+ * @see StandardReflectionParameterNameDiscoverer
40
+ * @see DefaultParameterNameDiscoverer
39
41
*/
40
42
public class KotlinReflectionParameterNameDiscoverer implements ParameterNameDiscoverer {
41
43
Original file line number Diff line number Diff line change 47
47
* caches the ASM discovered information for each introspected Class, in a thread-safe
48
48
* manner. It is recommended to reuse ParameterNameDiscoverer instances as far as possible.
49
49
*
50
+ * <p>This discoverer variant is effectively superseded by the Java 8 based
51
+ * {@link StandardReflectionParameterNameDiscoverer} but included as a fallback still
52
+ * (for code not compiled with the standard "-parameters" compiler flag).
53
+ *
50
54
* @author Adrian Colyer
51
55
* @author Costin Leau
52
56
* @author Juergen Hoeller
53
57
* @author Chris Beams
54
58
* @author Sam Brannen
55
59
* @since 2.0
60
+ * @see StandardReflectionParameterNameDiscoverer
61
+ * @see DefaultParameterNameDiscoverer
56
62
*/
57
63
public class LocalVariableTableParameterNameDiscoverer implements ParameterNameDiscoverer {
58
64
Original file line number Diff line number Diff line change 1
1
/*
2
- * Copyright 2002-2017 the original author or authors.
2
+ * Copyright 2002-2022 the original author or authors.
3
3
*
4
4
* Licensed under the Apache License, Version 2.0 (the "License");
5
5
* you may not use this file except in compliance with the License.
26
26
* {@link ParameterNameDiscoverer} implementation which uses JDK 8's reflection facilities
27
27
* for introspecting parameter names (based on the "-parameters" compiler flag).
28
28
*
29
+ * <p>This is a key element of {@link DefaultParameterNameDiscoverer} where it is being
30
+ * combined with {@link KotlinReflectionParameterNameDiscoverer} if Kotlin is present.
31
+ *
29
32
* @author Juergen Hoeller
30
33
* @since 4.0
31
34
* @see java.lang.reflect.Method#getParameters()
32
35
* @see java.lang.reflect.Parameter#getName()
36
+ * @see KotlinReflectionParameterNameDiscoverer
37
+ * @see DefaultParameterNameDiscoverer
33
38
*/
34
39
public class StandardReflectionParameterNameDiscoverer implements ParameterNameDiscoverer {
35
40
You can’t perform that action at this time.
0 commit comments