@Any should allow injection of type if exactly one bean present
---------------------------------------------------------------
Key: WBRI-282
URL:
https://jira.jboss.org/jira/browse/WBRI-282
Project: Web Beans
Issue Type: Bug
Components: Bootstrap
Affects Versions: 1.0.0.PREVIEW1
Reporter: Dan Allen
Assignee: Dan Allen
Priority: Minor
Fix For: 1.0.0.CR1
Typically @Any is used to inject a built-in type that allows dynamic select of a bean.
However, if there is exactly one bean of a type present, then @Any should be able to stand
in for @Current.
@Any Drink drink;
See AnyInjectionTest in the tck.
Currently, the RI is throwing the following exception:
"An injection point annotated javax.enterprise.inject.Any must have a type
parameter"
at org.jboss.webbeans.BeanValidator.checkFacadeInjectionPoint(BeanValidator.java:201)
at org.jboss.webbeans.BeanValidator.validate(BeanValidator.java:103)
at org.jboss.webbeans.bootstrap.WebBeansBootstrap.boot(WebBeansBootstrap.java:210)
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira