[jbosstools-issues] [JBoss JIRA] Commented: (JBIDE-4845) Introduce qualifier
Pete Muir (JIRA)
jira-events at lists.jboss.org
Mon Dec 14 08:16:30 EST 2009
[ https://jira.jboss.org/jira/browse/JBIDE-4845?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12499775#action_12499775 ]
Pete Muir commented on JBIDE-4845:
----------------------------------
For example, given these classes:
public class Foo {}
public class Bar extends Foo {}
public class Baz {
@Inject Foo foo;
}
will give you an AmbiguousResolutionException.
To fix this we change the classes to:
public class Foo {}
@Special
public class Bar extends Foo {}
public class Baz {
@Inject @Special Foo foo;
}
Here we have introduced a qualifier on both the injection point and the bean. If a qualifier existed already on the bean, we would just add it to the injection point.
Note that both Foo and Bar should be offered as places to add the qualifier.
> Introduce qualifier
> -------------------
>
> Key: JBIDE-4845
> URL: https://jira.jboss.org/jira/browse/JBIDE-4845
> Project: Tools (JBoss Tools)
> Issue Type: Feature Request
> Components: cdi (jsr-299)
> Affects Versions: LATER
> Reporter: Pete Muir
> Fix For: 3.1.0.GA
>
>
> Ability to introduce a qualifier at an IP
--
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
More information about the jbosstools-issues
mailing list