[jbosstools-issues] [JBoss JIRA] (JBIDE-15381) Support annotation @Vetoed

Viacheslav Kabanovich (JIRA) jira-events at lists.jboss.org
Mon Dec 2 14:18:05 EST 2013


    [ https://issues.jboss.org/browse/JBIDE-15381?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12927981#comment-12927981 ] 

Viacheslav Kabanovich commented on JBIDE-15381:
-----------------------------------------------

I cannot reproduce it.
1. Create class UserSession, producer with type UserSession in another class, and injection point with type UserSession.
Injection point is marked with "Multiple beans ..." - correct.
2. Annotate class UserSession with @Vetoed. Injection point is not marked and resolves to the producer - correct.
3. Remove annotation @Vetoed. Marker "Multiple beans ..." appears again - correct.
4. Move definition of producer into class UserSession. Marker remains - correct.
5.  Annotate class UserSession with @Vetoed. Marker appears "No bean is eligible ..."  - correct.
                
> Support annotation @Vetoed
> --------------------------
>
>                 Key: JBIDE-15381
>                 URL: https://issues.jboss.org/browse/JBIDE-15381
>             Project: Tools (JBoss Tools)
>          Issue Type: Sub-task
>          Components: cdi
>            Reporter: Viacheslav Kabanovich
>            Assignee: Viacheslav Kabanovich
>              Labels: new_and_noteworthy
>             Fix For: 4.2.0.Alpha1
>
>
> If class is anotated @Vetoed or if its package is annotated @Vetoed, then it is excluded from managed beans.
> Test with archive.
> 1. Import project /org.jboss.tools.cdi.core.test/projects/CDIArchivesTest
> 2. Open class test.a.Test
> 3. Check that injection @Inject Venus venus; is not satisfied because class test.d.planets.Venus in lib2/cdiastro.jar is annotated @Vetoed.
> 4. Check that injection @Inject Sirius sirius; is not satisfied because package test.d.stars in lib2/cdiastro.jar is annotated @Vetoed. (jar file contains sources to check that).
> Test with sources.
> 1. Import project /org.jboss.tools.cdi.core.test/projects/tck1.1
> 2. Open class org.jboss.jsr299.tck.tests.jbt.vetoed.Injections
> 3. Check that @Inject Pond pond; is not satisfied because org.jboss.jsr299.tck.tests.jbt.vetoed.Pond is annotated @Vetoed.
> 4. Check that @Inject Black black; is not satisfied because package org.jboss.jsr299.tck.tests.jbt.vetoed.seas is annotated @Vetoed (see package-info.java).
> 5. Check that @Inject Caspian caspian; is satisfied because package org.jboss.jsr299.tck.tests.jbt.vetoed.seas.inner is not annotated @Vetoed although it is a subpackage of an annotated package.
> 6. Check that @Inject Pond.Creek creek; is satisfied because class Pond.Creek is not annotated @Vetoed although it is a nested class in an annotated class.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


More information about the jbosstools-issues mailing list