Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVA

spring get bean with generic type

ResolvableType type = ResolvableType.forClassWithGenerics(ClassWithGenericType.class, GenericType.class);
ObjectProvider<Object> = applicationContext.getBeanProvider(type);
 
PREVIOUS NEXT
Tagged: #spring #bean #generic #type
ADD COMMENT
Topic
Name
8+2 =