Revised 4.3 signatures for MethodParameter/DependencyDescriptor

Issue: SPR-13440
This commit is contained in:
Juergen Hoeller
2016-03-23 18:52:27 +01:00
parent 9af12d290e
commit c5b318a4cc
2 changed files with 36 additions and 19 deletions

View File

@@ -180,6 +180,7 @@ public class DependencyDescriptor extends InjectionPoint implements Serializable
* @param beanName the bean name, as a candidate result for this dependency
* @param beanFactory the associated factory
* @return the bean instance (never {@code null})
* @since 4.3
* @see BeanFactory#getBean(String)
*/
public Object resolveCandidate(String beanName, BeanFactory beanFactory) {
@@ -278,6 +279,7 @@ public class DependencyDescriptor extends InjectionPoint implements Serializable
Type[] args = ((ParameterizedType) type).getActualTypeArguments();
type = args[args.length - 1];
}
// TODO: Object.class if unresolvable
}
if (type instanceof Class) {
return (Class<?>) type;