public class

AccessControlListTag

extends TagSupport
java.lang.Object
   ↳ TagSupport
     ↳ org.springframework.security.taglibs.authz.AccessControlListTag

Class Overview

An implementation of 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. The tag delegates to the configured PermissionEvaluator which it obtains from the ApplicationContext.

For this class to operate it must be able to access the application context via the WebApplicationContextUtils and attempt to locate the PermissionEvaluator instance. There cannot be more than one of these present for the tag to function.

Summary

Fields
protected static final Log logger
Public Constructors
AccessControlListTag()
Public Methods
int doStartTag()
Object getDomainObject()
String getHasPermission()
void setDomainObject(Object domainObject)
void setHasPermission(String hasPermission)
void setVar(String var)
Protected Methods
ApplicationContext getContext(PageContext pageContext)
Allows test cases to override where application context obtained from.
[Expand]
Inherited Methods
From class java.lang.Object

Fields

protected static final Log logger

Public Constructors

public AccessControlListTag ()

Public Methods

public int doStartTag ()

Throws
JspException

public Object getDomainObject ()

public String getHasPermission ()

public void setDomainObject (Object domainObject)

public void setHasPermission (String hasPermission)

public void setVar (String var)

Protected Methods

protected ApplicationContext getContext (PageContext pageContext)

Allows test cases to override where application context obtained from.

Parameters
pageContext so the ServletContext can be accessed as required by Spring's WebApplicationContextUtils
Returns
  • the Spring application context (never null)