Class PostFilterAuthorizationMethodInterceptor
- java.lang.Object
-
- org.springframework.security.authorization.method.PostFilterAuthorizationMethodInterceptor
-
- All Implemented Interfaces:
org.aopalliance.aop.Advice
,org.aopalliance.intercept.Interceptor
,org.aopalliance.intercept.MethodInterceptor
,org.springframework.aop.Advisor
,org.springframework.aop.framework.AopInfrastructureBean
,org.springframework.aop.PointcutAdvisor
,org.springframework.core.Ordered
public final class PostFilterAuthorizationMethodInterceptor extends java.lang.Object implements org.springframework.core.Ordered, org.aopalliance.intercept.MethodInterceptor, org.springframework.aop.PointcutAdvisor, org.springframework.aop.framework.AopInfrastructureBean
AMethodInterceptor
which filters areturnedObject
from theMethodInvocation
by evaluating an expression from thePostFilter
annotation.- Since:
- 5.6
-
-
Constructor Summary
Constructors Constructor Description PostFilterAuthorizationMethodInterceptor()
Creates aPostFilterAuthorizationMethodInterceptor
using the provided parameters
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.aopalliance.aop.Advice
getAdvice()
int
getOrder()
org.springframework.aop.Pointcut
getPointcut()
java.lang.Object
invoke(org.aopalliance.intercept.MethodInvocation mi)
boolean
isPerInstance()
void
setExpressionHandler(MethodSecurityExpressionHandler expressionHandler)
Use thisMethodSecurityExpressionHandler
.void
setOrder(int order)
void
setSecurityContextHolderStrategy(SecurityContextHolderStrategy strategy)
Sets theSecurityContextHolderStrategy
to use.
-
-
-
Constructor Detail
-
PostFilterAuthorizationMethodInterceptor
public PostFilterAuthorizationMethodInterceptor()
Creates aPostFilterAuthorizationMethodInterceptor
using the provided parameters
-
-
Method Detail
-
setExpressionHandler
public void setExpressionHandler(MethodSecurityExpressionHandler expressionHandler)
Use thisMethodSecurityExpressionHandler
.- Parameters:
expressionHandler
- theMethodSecurityExpressionHandler
to use
-
getOrder
public int getOrder()
- Specified by:
getOrder
in interfaceorg.springframework.core.Ordered
-
setOrder
public void setOrder(int order)
-
getPointcut
public org.springframework.aop.Pointcut getPointcut()
- Specified by:
getPointcut
in interfaceorg.springframework.aop.PointcutAdvisor
-
getAdvice
public org.aopalliance.aop.Advice getAdvice()
- Specified by:
getAdvice
in interfaceorg.springframework.aop.Advisor
-
isPerInstance
public boolean isPerInstance()
- Specified by:
isPerInstance
in interfaceorg.springframework.aop.Advisor
-
setSecurityContextHolderStrategy
public void setSecurityContextHolderStrategy(SecurityContextHolderStrategy strategy)
Sets theSecurityContextHolderStrategy
to use. The default action is to use theSecurityContextHolderStrategy
stored inSecurityContextHolder
.- Since:
- 5.8
-
invoke
public java.lang.Object invoke(org.aopalliance.intercept.MethodInvocation mi) throws java.lang.Throwable
- Specified by:
invoke
in interfaceorg.aopalliance.intercept.MethodInterceptor
- Parameters:
mi
- theMethodInvocation
to check check- Returns:
- filtered
returnedObject
- Throws:
java.lang.Throwable
-
-