<div>ObserverMethod.notify(T, Set<Annotation>) might work. It seems minimalistic and would be optionally injected. I've made the relevant code changes to support this; however, I'm not sure the best way to implement the actually injection of Set<Annotation> on an observer method. e.g. void onEvent(@Observes String s, Set<Annotation> qualifiers, <other injection point references>)</div>
<div><br></div><div>Would it be useful for MethodInjectionPoint to define invokeOnInstanceWithSpecialValue(..) allowing more than one special value so the qualifiers could be provided directly?</div><div><br></div><div>Is there a better way to provide the qualifier set as a parameter?</div>
<div><br></div><div><br></div><div><div class="gmail_quote">On Mon, Jan 25, 2010 at 8:37 PM, Gavin King <span dir="ltr"><<a href="mailto:gavin.king@gmail.com" target="_blank">gavin.king@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
I think the real problem is with the signature of the notify() method<br>
of this interface:<br>
<br>
<a href="http://docs.jboss.org/cdi/api/1.0/" target="_blank">http://docs.jboss.org/cdi/api/1.0/</a><br>
<div><div></div><div><br>
On Mon, Jan 18, 2010 at 9:49 PM, Jordan Ganoff <<a href="mailto:jganoff@gmail.com" target="_blank">jganoff@gmail.com</a>> wrote:<br>
> Just brainstorming here but:<br>
> 1) Methods could observe the raw Event<Type> to receive all events of that<br>
> type. Then Event would need to expose the qualifiers publicly - maybe as<br>
> high up as AbstractFacade?<br>
> Something like: public void allStrings(@Observes Event<String> event);<br>
> 2) Allow registration of a new interface: EventHandler.<br>
> BeanManager.fireEvent() would be required to fire the event on all<br>
> registered handlers. The current event observer resolver would be the first<br>
> implementation of this.<br>
> 3) Same idea as #2 but restricted to Portable Extensions.<br>
> Good/bad?<br>
><br>
> On Mon, Jan 18, 2010 at 5:36 PM, Gavin King <<a href="mailto:gavin.king@gmail.com" target="_blank">gavin.king@gmail.com</a>> wrote:<br>
>><br>
>> Hrm. That's true. That's on oversight. Do you have a proposed solution<br>
>> to this problem? I would be open to addressing this issue in the CDI<br>
>> MR.<br>
>><br>
>> On Sun, Jan 17, 2010 at 11:19 AM, Jordan Ganoff <<a href="mailto:jganoff@gmail.com" target="_blank">jganoff@gmail.com</a>> wrote:<br>
>> > I'm trying to route Events from a portable extension (to be the Seam 3<br>
>> > JMS<br>
>> > module). After talking to David Allen it seems there is currently no<br>
>> > way to<br>
>> > get the qualifiers for a fired event. Without the qualifiers it doesn't<br>
>> > seem like routing outside of Weld-core is possible. The idea of using<br>
>> > an<br>
>> > Interceptor on BeanManager.fireEvent() would have worked but we can't<br>
>> > assign<br>
>> > Interceptors to an existing class.<br>
>> > Any ideas?<br>
>> > --<br>
>> > Jordan Ganoff<br>
>> > _______________________________________________<br>
>> > weld-dev mailing list<br>
>> > <a href="mailto:weld-dev@lists.jboss.org" target="_blank">weld-dev@lists.jboss.org</a><br>
>> > <a href="https://lists.jboss.org/mailman/listinfo/weld-dev" target="_blank">https://lists.jboss.org/mailman/listinfo/weld-dev</a><br>
>> ><br>
>><br>
>><br>
>><br>
>> --<br>
>> Gavin King<br>
>> <a href="mailto:gavin.king@gmail.com" target="_blank">gavin.king@gmail.com</a><br>
>> <a href="http://in.relation.to/Bloggers/Gavin" target="_blank">http://in.relation.to/Bloggers/Gavin</a><br>
>> <a href="http://hibernate.org" target="_blank">http://hibernate.org</a><br>
>> <a href="http://seamframework.org" target="_blank">http://seamframework.org</a><br>
><br>
><br>
<br>
<br>
<br>
</div></div>--<br>
<div><div></div><div>Gavin King<br>
<a href="mailto:gavin.king@gmail.com" target="_blank">gavin.king@gmail.com</a><br>
<a href="http://in.relation.to/Bloggers/Gavin" target="_blank">http://in.relation.to/Bloggers/Gavin</a><br>
<a href="http://hibernate.org" target="_blank">http://hibernate.org</a><br>
<a href="http://seamframework.org" target="_blank">http://seamframework.org</a><br>
</div></div></blockquote></div><br><br clear="all"><br>-- <br>Jordan Ganoff<br>
</div>