openwebbeans-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mark Struberg <strub...@yahoo.de>
Subject Re: @Produce a generic type?
Date Mon, 15 May 2017 20:14:04 GMT
Yes, but only if the producer has a @Dependent scope.

For other scopes there is a trick by using ProcessInjectionPoint to collect the information.
And later add Beans for each different InjectionPoint type.

LieGrue,
strub

> Am 15.05.2017 um 20:28 schrieb James Carman <james@carmanconsulting.com>:
> 
> I am trying to support this pattern:
> 
> @Inject
> private JaxrsProxy<HelloResource> helloResource;
> 
> I am trying to create a @Produces method that takes in an InjectionPoint to determine
the "HelloResource" type parameter on the field and create a dynamic proxy using a separate
"factory" bean.  Is this pattern even possible?  
> 
> Thanks,
> 
> James
> 


Mime
View raw message