-
Clarification
-
Resolution: Obsolete
-
Major
-
None
-
None
CDI 1.1, section 2.2.1. Legal bean types says:
A parameterized type that contains a wildcard type parameter is not a legal bean type.
Does it means direct containment or deep/recursive containment?
I understand this is clearly illegal:
@Produces
List<?> produceList(){
//...
}
But, are those two bean definitions legal:
@Produces
List<Optional<?>> produceList(){
//...
}
// Bean types: MyList, List<Optional<?>>, Object // or // Bean types: MyList, Object @Dependent MyList extends List<Optional<?>> { //... }
- relates to
-
WELD-1492 Producers with parameterized return types with a nested parameterized type containing a wildcard or type variable are not detected as invalid
- Resolved