public class AccessControlListTag
extends javax.servlet.jsp.tagext.TagSupport
Tag that allows its body through if some authorizations
are granted to the request's principal.One or more comma separate numeric are specified via the
hasPermission attribute. Those permissions are then converted into Permission instances. These
instances are then presented as an array to the Acl.isGranted(Permission[],
org.acegisecurity.acls.sid.Sid[], boolean) method. The Sid presented is determined by the SidRetrievalStrategy.
For this class to operate it must be able to access the application context via the
WebApplicationContextUtils and locate an AclService and SidRetrievalStrategy.
Application contexts must provide one and only one of these Java types.
| Modifier and Type | Field and Description |
|---|---|
protected static org.apache.commons.logging.Log |
logger |
| Constructor and Description |
|---|
AccessControlListTag() |
| Modifier and Type | Method and Description |
|---|---|
int |
doStartTag() |
protected org.springframework.context.ApplicationContext |
getContext(javax.servlet.jsp.PageContext pageContext)
Allows test cases to override where application context obtained from.
|
Object |
getDomainObject() |
String |
getHasPermission() |
void |
setDomainObject(Object domainObject) |
void |
setHasPermission(String hasPermission) |
public int doStartTag()
throws javax.servlet.jsp.JspException
doStartTag in interface javax.servlet.jsp.tagext.TagdoStartTag in class javax.servlet.jsp.tagext.TagSupportjavax.servlet.jsp.JspExceptionprotected org.springframework.context.ApplicationContext getContext(javax.servlet.jsp.PageContext pageContext)
pageContext - so the ServletContext can be accessed as required by Spring's
WebApplicationContextUtilsnull)public Object getDomainObject()
public String getHasPermission()
public void setDomainObject(Object domainObject)
public void setHasPermission(String hasPermission)
Copyright © 2021. All rights reserved.