Class AccessControlListTag
- java.lang.Object
-
- javax.servlet.jsp.tagext.TagSupport
-
- org.springframework.security.taglibs.authz.AccessControlListTag
-
- All Implemented Interfaces:
java.io.Serializable,javax.servlet.jsp.tagext.IterationTag,javax.servlet.jsp.tagext.JspTag,javax.servlet.jsp.tagext.Tag
public class AccessControlListTag extends javax.servlet.jsp.tagext.TagSupportAn implementation ofTagthat allows its body through if all authorizations are granted to the request's principal.One or more comma separate numeric are specified via the
hasPermissionattribute. The tag delegates to the configuredPermissionEvaluatorwhich it obtains from theApplicationContext.For this class to operate it must be able to access the application context via the
WebApplicationContextUtilsand attempt to locate thePermissionEvaluatorinstance. There cannot be more than one of these present for the tag to function.- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected static org.apache.commons.logging.Loglogger
-
Constructor Summary
Constructors Constructor Description AccessControlListTag()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intdoStartTag()protected org.springframework.context.ApplicationContextgetContext(javax.servlet.jsp.PageContext pageContext)Allows test cases to override where application context obtained from.java.lang.ObjectgetDomainObject()java.lang.StringgetHasPermission()voidsetDomainObject(java.lang.Object domainObject)voidsetHasPermission(java.lang.String hasPermission)voidsetVar(java.lang.String var)
-
-
-
Method Detail
-
doStartTag
public int doStartTag() throws javax.servlet.jsp.JspException- Specified by:
doStartTagin interfacejavax.servlet.jsp.tagext.Tag- Overrides:
doStartTagin classjavax.servlet.jsp.tagext.TagSupport- Throws:
javax.servlet.jsp.JspException
-
getContext
protected org.springframework.context.ApplicationContext getContext(javax.servlet.jsp.PageContext pageContext)
Allows test cases to override where application context obtained from.- Parameters:
pageContext- so theServletContextcan be accessed as required by Spring'sWebApplicationContextUtils- Returns:
- the Spring application context (never
null)
-
getDomainObject
public java.lang.Object getDomainObject()
-
getHasPermission
public java.lang.String getHasPermission()
-
setDomainObject
public void setDomainObject(java.lang.Object domainObject)
-
setHasPermission
public void setHasPermission(java.lang.String hasPermission)
-
setVar
public void setVar(java.lang.String var)
-
-