The Seam events functionality in CVS is pretty useful. I prefer using the
annotations over events.xml but I find the annotations less flexible.
I would like to allow one method to observe multiple event types. How about
adding an @Observers annotation that works like @Roles? Here is an an example:
| @Observers({
| @Observer("somethingChanged"),
| @Observer("somethingElseChanged")
| })
| public void refresh() {
| ...
| }
|
This would make my code cleaner especially if I'm observing many event types.
Another suggestion is to add a priority hint to the @Observer annotation. This
could just be an arbitrary number (like a z-index) that allows Observer
instances to be sorted, allowing methods observing the same event type to be
fired in a sensible order. Here is an example:
| @Observer("somethingChanged", 0)
| public void meFirst() {
| ...
| }
|
| @Observer("somethingChanged", 100)
| public void meNext() {
| ...
| }
|
I hope this makes sense, I'll add this to JIRA if you think so.
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3940524#3940524
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3940524
-------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
JBoss-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jboss-user