File tree Expand file tree Collapse file tree 1 file changed +6
-0
lines changed
spring-aop/src/main/java/org/springframework/aop/support Expand file tree Collapse file tree 1 file changed +6
-0
lines changed Original file line number Diff line number Diff line change @@ -193,6 +193,12 @@ public static boolean isFinalizeMethod(@Nullable Method method) {
193
193
*/
194
194
public static Method getMostSpecificMethod (Method method , @ Nullable Class <?> targetClass ) {
195
195
Class <?> specificTargetClass = (targetClass != null ? ClassUtils .getUserClass (targetClass ) : null );
196
+ Class <?>[] interfaces = targetClass .getInterfaces ();
197
+ for (Class <?> itf : interfaces ) {
198
+ Method mostSpecificMethod = getMostSpecificMethod (method , itf );
199
+ if (mostSpecificMethod != method )
200
+ return mostSpecificMethod ;
201
+ }
196
202
Method resolvedMethod = ClassUtils .getMostSpecificMethod (method , specificTargetClass );
197
203
// If we are dealing with method with generic parameters, find the original method.
198
204
return BridgeMethodResolver .findBridgedMethod (resolvedMethod );
You can’t perform that action at this time.
0 commit comments