org.springframework.aop.aspectj
Class AspectJAroundAdvice
java.lang.Object
org.springframework.aop.aspectj.AbstractAspectJAdvice
org.springframework.aop.aspectj.AspectJAroundAdvice
- All Implemented Interfaces:
- AspectJPrecedenceInformation, Ordered
public class AspectJAroundAdvice
- extends AbstractAspectJAdvice
Spring AOP around advice (MethodInterceptor) that wraps
an AspectJ advice method. Exposes ProceedingJoinPoint.
- Since:
- 2.0
- Author:
- Rod Johnson, Juergen Hoeller
Methods inherited from class org.springframework.aop.aspectj.AbstractAspectJAdvice |
argBinding, buildSafePointcut, calculateArgumentBindings, createParameterNameDiscoverer, currentJoinPoint, getAspectClassLoader, getAspectInstanceFactory, getAspectJAdviceMethod, getAspectName, getDeclarationOrder, getDiscoveredReturningGenericType, getDiscoveredReturningType, getDiscoveredThrowingType, getJoinPoint, getJoinPointMatch, getJoinPointMatch, getOrder, getPointcut, invokeAdviceMethod, invokeAdviceMethod, invokeAdviceMethodWithGivenArgs, setArgumentNames, setArgumentNamesFromStringArray, setAspectName, setDeclarationOrder, setReturningName, setReturningNameNoCheck, setThrowingName, setThrowingNameNoCheck, toString |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
AspectJAroundAdvice
public AspectJAroundAdvice(java.lang.reflect.Method aspectJAroundAdviceMethod,
AspectJExpressionPointcut pointcut,
AspectInstanceFactory aif)
isBeforeAdvice
public boolean isBeforeAdvice()
- Description copied from interface:
AspectJPrecedenceInformation
- Return whether this is a before advice.
isAfterAdvice
public boolean isAfterAdvice()
- Description copied from interface:
AspectJPrecedenceInformation
- Return whether this is an after advice.
supportsProceedingJoinPoint
protected boolean supportsProceedingJoinPoint()
- Overrides:
supportsProceedingJoinPoint
in class AbstractAspectJAdvice
invoke
public java.lang.Object invoke(MethodInvocation mi)
throws java.lang.Throwable
- Throws:
java.lang.Throwable
lazyGetProceedingJoinPoint
protected ProceedingJoinPoint lazyGetProceedingJoinPoint(ProxyMethodInvocation rmi)
- Return the ProceedingJoinPoint for the current invocation,
instantiating it lazily if it hasn't been bound to the thread already.
- Parameters:
rmi
- the current Spring AOP ReflectiveMethodInvocation,
which we'll use for attribute binding
- Returns:
- the ProceedingJoinPoint to make available to advice methods