public class GuestAnnotationHandler extends AuthorizingAnnotationHandler
RequiresGuestannotation is declared, and if so, ensures the calling
Subjectdoes not have an
identitybefore invoking the method.
This annotation essentially ensures that
getPrincipal() == null
|Constructor and Description|
Default no-argument constructor that ensures this interceptor looks for
|Modifier and Type||Method and Description|
Ensures that the calling
getAnnotationClass, getSubject, setAnnotationClass
public void assertAuthorized(Annotation a) throws AuthorizationException
Subjectis NOT a user, that is, they do not have an
identitybefore continuing. If they are a user (
Subject.getPrincipal()!= null), an
AuthorizingExceptionwill be thrown indicating that execution is not allowed to continue.
Copyright © 2004–2019 The Apache Software Foundation. All rights reserved.