what are the exact semantics of before/after?

You get the same thing with around.  You want before?


  | try
  | {
  |     doBefore();
  |      invocation.invokeNext();
  | }
  | 

You want after?


  | try
  | {
  |    Object rtn = invocation.invokeNext();
  |     doAfter();
  |      return rtn;
  | }
  | 

You want after throwing?

  | try
  | {
  |    return invocation.invokeNext();
  | }
  | catch (Exception ex)
  | {
  |    afterThrowing();
  |    throw ex;
  | }
  | 

IMO, I'd rather have the aspect developer thinking in java call stacks and using 
try/catch/finally blocks.  

Less is better, IMO.

Bill

View the original post : 
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3849415#3849415

Reply to the post : 
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3849415


-------------------------------------------------------
This SF.Net email is sponsored by: YOU BE THE JUDGE. Be one of 170
Project Admins to receive an Apple iPod Mini FREE for your judgement on
who ports your project to Linux PPC the best. Sponsored by IBM.
Deadline: Sept. 24. Go here: http://sf.net/ppc_contest.php
_______________________________________________
JBoss-Development mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-development

Reply via email to