Actually, I am wrong, the spec does support this (though the TCK doesn't check it
explicitly).
From 5.5.7
"The container must provide a bean with scope @Dependent, bean type InjectionPoint
and qualifier @Default, allowing dependent objects, as defined in Section 6.4.1,
“Dependent objects”, to obtain information about the injection point to which they
belong."
So you can do a dynamic lookup using the beanManager inside your create() method.
If you want this tested by the TCK, then file a CDI TCK issue :-)
On 20 Apr 2010, at 11:20, Pete Muir wrote:
Agreed. The spec doesn't allow this.
I believe in Weld you should be able to do a dynamic lookup though (but no guarantee
about other containers of course!).
On 20 Apr 2010, at 09:46, Stuart Douglas wrote:
> Unless I am missing something it does not seem to be possible for a custom dependant
scoped Bean implementation to get information about it's injection point.
>
> If this is the case, is this something that could be addressed in the maintenance
release?
>
> Stuart
> _______________________________________________
> weld-dev mailing list
> weld-dev(a)lists.jboss.org
>
https://lists.jboss.org/mailman/listinfo/weld-dev