Tutorial Question #2

129 views
Skip to first unread message

mottagio

unread,
Oct 31, 2011, 1:14:10 PM10/31/11
to CDI Advocate
In the section "Advanced Using @Nonbinding to combine a configuration
annotation and a qaulifier annotation into one annotation", i don't
understand how does "retries=9" get injected...When i try, it is not.

In previous section, injection is performed in TransportFactory class,
but with a "static" instantiation of the injected member:

StandardAtmTransport transport = new
StandardAtmTransport();
transport.setRetries(transportConfig.retries());

I think some code is required to make the "@Nonbinding " sample work
that is not specified.

Please clarify, thank you

Camilo Robayo

unread,
Dec 18, 2014, 7:40:57 PM12/18/14
to cdiadv...@googlegroups.com
Something that I can´t get is when inject via }

    @Inject
    @Transport(type=TransportType.STANDARD, priorityLevel=1, name="super", retries = 9)
    private ATMTransport transportDefault;
   
Its not producer by TransportFactory, and transportDefatul is SuperFastAtmTranssport but retries=0

Could you find a solution
Reply all
Reply to author
Forward
0 new messages