Class AopAllianceAnnotationsAuthorizingMethodInterceptor
- java.lang.Object
-
- org.apache.shiro.aop.MethodInterceptorSupport
-
- org.apache.shiro.authz.aop.AuthorizingMethodInterceptor
-
- org.apache.shiro.authz.aop.AnnotationsAuthorizingMethodInterceptor
-
- org.apache.shiro.spring.security.interceptor.AopAllianceAnnotationsAuthorizingMethodInterceptor
-
- All Implemented Interfaces:
org.aopalliance.aop.Advice,org.aopalliance.intercept.Interceptor,org.aopalliance.intercept.MethodInterceptor,org.apache.shiro.aop.MethodInterceptor
public class AopAllianceAnnotationsAuthorizingMethodInterceptor extends org.apache.shiro.authz.aop.AnnotationsAuthorizingMethodInterceptor implements org.aopalliance.intercept.MethodInterceptorAllows Shiro Annotations to work in any AOP Alliance specific implementation environment (for example, Spring).- Since:
- 0.2
-
-
Constructor Summary
Constructors Constructor Description AopAllianceAnnotationsAuthorizingMethodInterceptor()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected ObjectcontinueInvocation(Object aopAllianceMethodInvocation)Simply casts the method argument to anorg.aopalliance.intercept.MethodInvocationand then callsmethodInvocation.proceed()protected org.apache.shiro.aop.MethodInvocationcreateMethodInvocation(Object implSpecificMethodInvocation)Creates aMethodInvocationthat wraps anorg.aopalliance.intercept.MethodInvocationinstance, enabling Shiro Annotations in AOP Alliance environments (Spring, etc).Objectinvoke(org.aopalliance.intercept.MethodInvocation methodInvocation)Creates a ShiroMethodInvocationinstance and then immediately callssuper.invoke.
-
-
-
Method Detail
-
createMethodInvocation
protected org.apache.shiro.aop.MethodInvocation createMethodInvocation(Object implSpecificMethodInvocation)
Creates aMethodInvocationthat wraps anorg.aopalliance.intercept.MethodInvocationinstance, enabling Shiro Annotations in AOP Alliance environments (Spring, etc).- Parameters:
implSpecificMethodInvocation- AOP AllianceMethodInvocation- Returns:
- a Shiro
MethodInvocationinstance that wraps the AOP Alliance instance.
-
continueInvocation
protected Object continueInvocation(Object aopAllianceMethodInvocation) throws Throwable
Simply casts the method argument to anorg.aopalliance.intercept.MethodInvocationand then callsmethodInvocation.proceed()- Parameters:
aopAllianceMethodInvocation- theorg.aopalliance.intercept.MethodInvocation- Returns:
- the
org.aopalliance.intercept.MethodInvocation.proceed()method call result. - Throws:
Throwable- if the underlying AOP Allianceproceed()call throws aThrowable.
-
invoke
public Object invoke(org.aopalliance.intercept.MethodInvocation methodInvocation) throws Throwable
Creates a ShiroMethodInvocationinstance and then immediately callssuper.invoke.- Specified by:
invokein interfaceorg.aopalliance.intercept.MethodInterceptor- Parameters:
methodInvocation- the AOP Alliance-specificmethodInvocationinstance.- Returns:
- the return value from invoking the method invocation.
- Throws:
Throwable- if the underlying AOP Alliance method invocation throws aThrowable.
-
-