20
20
import java .util .Collections ;
21
21
import java .util .List ;
22
22
23
- import org .springframework .expression .PropertyAccessor ;
24
23
import org .springframework .expression .TargetedAccessor ;
25
24
import org .springframework .lang .Nullable ;
26
25
import org .springframework .util .ObjectUtils ;
32
31
* @author Sam Brannen
33
32
* @since 3.0.2
34
33
*/
35
- public abstract class AstUtils {
34
+ abstract class AstUtils {
36
35
37
36
/**
38
37
* Determine the set of accessors that should be used to try to access an
@@ -52,7 +51,7 @@ public abstract class AstUtils {
52
51
* accessor could be found
53
52
* @since 6.2
54
53
*/
55
- public static <T extends TargetedAccessor > List <T > getAccessorsToTry (
54
+ static <T extends TargetedAccessor > List <T > getAccessorsToTry (
56
55
@ Nullable Class <?> targetType , List <T > accessors ) {
57
56
58
57
if (accessors .isEmpty ()) {
@@ -93,28 +92,4 @@ else if (clazz.isAssignableFrom(targetType)) {
93
92
}
94
93
}
95
94
96
- /**
97
- * Determine the set of property accessors that should be used to try to
98
- * access a property on the specified target type.
99
- * <p>The accessors are considered to be in an ordered list; however, in the
100
- * returned list any accessors that are exact matches for the input target
101
- * type (as opposed to 'generic' accessors that could work for any type) are
102
- * placed at the start of the list. In addition, if there are specific
103
- * accessors that exactly name the class in question and accessors that name
104
- * a specific class which is a supertype of the class in question, the latter
105
- * are put at the end of the specific accessors set and will be tried after
106
- * exactly matching accessors but before generic accessors.
107
- * @param targetType the type upon which property access is being attempted
108
- * @param propertyAccessors the list of property accessors to process
109
- * @return a list of accessors that should be tried in order to access the
110
- * property on the specified target type, or an empty list if no suitable
111
- * accessor could be found
112
- * @see #getAccessorsToTry(Class, List)
113
- */
114
- public static List <PropertyAccessor > getPropertyAccessorsToTry (
115
- @ Nullable Class <?> targetType , List <PropertyAccessor > propertyAccessors ) {
116
-
117
- return getAccessorsToTry (targetType , propertyAccessors );
118
- }
119
-
120
95
}
0 commit comments