org.apache.shiro.authz.aop
Class UserAnnotationMethodInterceptor
java.lang.Object
org.apache.shiro.aop.MethodInterceptorSupport
org.apache.shiro.aop.AnnotationMethodInterceptor
org.apache.shiro.authz.aop.AuthorizingAnnotationMethodInterceptor
org.apache.shiro.authz.aop.UserAnnotationMethodInterceptor
- All Implemented Interfaces:
- MethodInterceptor
public class UserAnnotationMethodInterceptor
- extends AuthorizingAnnotationMethodInterceptor
Checks to see if a @RequiresUser
annotation
is declared, and if so, ensures the calling Subject
is either
authenticated
or remembered via remember
me services before invoking the method.
This annotation essentially ensures that subject.getPrincipal()
!= null
.
- Since:
- 0.9.0
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
UserAnnotationMethodInterceptor
public UserAnnotationMethodInterceptor()
- Default no-argument constructor that ensures this interceptor looks for
RequiresUser
annotations in a method
declaration.
UserAnnotationMethodInterceptor
public UserAnnotationMethodInterceptor(AnnotationResolver resolver)
- Parameters:
resolver
- - Since:
- 1.1
Copyright © 2004-2012 The Apache Software Foundation. All Rights Reserved.