1 22 package org.jboss.test.aop.regression.jbaop248annotationoverride; 23 24 import org.jboss.aop.advice.Interceptor; 25 import org.jboss.aop.joinpoint.Invocation; 26 27 32 public class TestInterceptor implements Interceptor 33 { 34 public static Class annotation; 35 public static Object classAnnotation; 36 public static Object joinpointAnnotation; 37 38 public static void reset() 39 { 40 classAnnotation = null; 41 joinpointAnnotation = null; 42 } 43 44 public String getName() 45 { 46 return TestInterceptor.class.getName(); 47 } 48 49 public Object invoke(Invocation invocation) throws Throwable 50 { 51 classAnnotation = invocation.resolveClassAnnotation(annotation); 52 joinpointAnnotation = invocation.resolveAnnotation(annotation); 53 54 return invocation.invokeNext(); 55 } 56 57 58 } 59 | Popular Tags |