spring-framework / org.springframework.aop.framework.adapter / AdvisorAdapter / getInterceptor

getInterceptor

abstract fun getInterceptor(advisor: Advisor): MethodInterceptor

Return an AOP Alliance MethodInterceptor exposing the behavior of the given advice to an interception-based AOP framework.

Don't worry about any Pointcut contained in the Advisor; the AOP framework will take care of checking the pointcut.

Parameters

advisor - the Advisor. The supportsAdvice() method must have returned true on this object

Return
an AOP Alliance interceptor for this Advisor. There's no need to cache instances for efficiency, as the AOP framework caches advice chains.