1 22 package org.jboss.test.aop.jdk15.annotated; 23 24 import org.jboss.aop.Bind; 25 import org.jboss.aop.InterceptorDef; 26 import org.jboss.aop.advice.Interceptor; 27 import org.jboss.aop.joinpoint.Invocation; 28 29 34 @InterceptorDef (scope=org.jboss.aop.advice.Scope.PER_VM) 35 @Bind (pointcut="execution(* org.jboss.test.aop.jdk15.annotated.VariaPOJO->precedenceMethod())") 36 public class PrecedenceInterceptor2 implements Interceptor 37 { 38 39 public String getName() 40 { 41 return "PrecedenceInterceptor2"; 42 } 43 44 public Object invoke(Invocation invocation) throws Throwable 45 { 46 Interceptions.add("PrecedenceInterceptor2"); 47 System.out.println("PrecedenceInterceptor2"); 48 return invocation.invokeNext(); 49 } 50 } 51 | Popular Tags |