Search in sources :

Example 76 with Advisor

use of cn.taketoday.aop.Advisor in project today-framework by TAKETODAY.

the class SimpleBeforeAdviceInterceptor method getAdviceImpl.

private SimpleBeforeAdviceImpl getAdviceImpl(ITestBean tb) {
    Advised advised = (Advised) tb;
    Advisor advisor = advised.getAdvisors()[0];
    return (SimpleBeforeAdviceImpl) advisor.getAdvice();
}
Also used : Advised(cn.taketoday.aop.framework.Advised) Advisor(cn.taketoday.aop.Advisor)

Aggregations

Advisor (cn.taketoday.aop.Advisor)76 Test (org.junit.jupiter.api.Test)70 DefaultPointcutAdvisor (cn.taketoday.aop.support.DefaultPointcutAdvisor)52 ITestBean (cn.taketoday.beans.testfixture.beans.ITestBean)43 TestBean (cn.taketoday.beans.testfixture.beans.TestBean)41 DefaultIntroductionAdvisor (cn.taketoday.aop.support.DefaultIntroductionAdvisor)32 NopInterceptor (cn.taketoday.aop.testfixture.interceptor.NopInterceptor)22 AspectJPointcutAdvisor (cn.taketoday.aop.aspectj.AspectJPointcutAdvisor)21 StaticMethodMatcherPointcutAdvisor (cn.taketoday.aop.support.StaticMethodMatcherPointcutAdvisor)20 CountingBeforeAdvice (cn.taketoday.aop.testfixture.advice.CountingBeforeAdvice)16 Method (java.lang.reflect.Method)16 SerializableNopInterceptor (cn.taketoday.aop.testfixture.interceptor.SerializableNopInterceptor)14 LockMixinAdvisor (test.mixin.LockMixinAdvisor)14 Advised (cn.taketoday.aop.framework.Advised)13 NopInterceptor (cn.taketoday.aop.NopInterceptor)10 ProxyFactory (cn.taketoday.aop.framework.ProxyFactory)10 Nullable (cn.taketoday.lang.Nullable)10 NameMatchMethodPointcut (cn.taketoday.aop.support.NameMatchMethodPointcut)8 JoinPoint (org.aspectj.lang.JoinPoint)8 ProceedingJoinPoint (org.aspectj.lang.ProceedingJoinPoint)8