Liferay 7.0-ce-b4

com.liferay.taglib.security
Class PermissionsURLTag

java.lang.Object
  extended by javax.servlet.jsp.tagext.TagSupport
      extended by com.liferay.taglib.security.PermissionsURLTag
All Implemented Interfaces:
Serializable, javax.servlet.jsp.tagext.IterationTag, javax.servlet.jsp.tagext.JspTag, javax.servlet.jsp.tagext.Tag

public class PermissionsURLTag
extends javax.servlet.jsp.tagext.TagSupport

See Also:
Serialized Form

Field Summary
 
Fields inherited from class javax.servlet.jsp.tagext.TagSupport
id, pageContext
 
Fields inherited from interface javax.servlet.jsp.tagext.IterationTag
EVAL_BODY_AGAIN
 
Fields inherited from interface javax.servlet.jsp.tagext.Tag
EVAL_BODY_INCLUDE, EVAL_PAGE, SKIP_BODY, SKIP_PAGE
 
Constructor Summary
PermissionsURLTag()
           
 
Method Summary
 int doEndTag()
           
static String doTag(String redirect, String modelResource, String modelResourceDescription, Object resourceGroupId, String resourcePrimKey, String windowState, int[] roleTypes, javax.servlet.http.HttpServletRequest request)
          Returns the URL for opening the resource's permissions configuration dialog and for configuring the resource's permissions.
 void setModelResource(String modelResource)
           
 void setModelResourceDescription(String modelResourceDescription)
           
 void setRedirect(String redirect)
           
 void setResourceGroupId(Object resourceGroupId)
           
 void setResourcePrimKey(String resourcePrimKey)
           
 void setRoleTypes(int[] roleTypes)
           
 void setVar(String var)
           
 void setWindowState(String windowState)
           
 
Methods inherited from class javax.servlet.jsp.tagext.TagSupport
doAfterBody, doStartTag, findAncestorWithClass, getId, getParent, getValue, getValues, release, removeValue, setId, setPageContext, setParent, setValue
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PermissionsURLTag

public PermissionsURLTag()
Method Detail

doTag

public static String doTag(String redirect,
                           String modelResource,
                           String modelResourceDescription,
                           Object resourceGroupId,
                           String resourcePrimKey,
                           String windowState,
                           int[] roleTypes,
                           javax.servlet.http.HttpServletRequest request)
                    throws Exception
Returns the URL for opening the resource's permissions configuration dialog and for configuring the resource's permissions.

Parameters:
redirect - the redirect. If the redirect is null or the dialog does not open as a pop-up, the current URL is obtained via PortalUtil.getCurrentURL(HttpServletRequest) and used.
modelResource - the resource's class for which to configure permissions
modelResourceDescription - the human-friendly description of the resource
resourceGroupId - the group ID to which the resource belongs. The ID can be a number, string containing a number, or substitution string. If the resource group ID is null, it is obtained via ThemeDisplay.getScopeGroupId().
resourcePrimKey - the primary key of the resource
windowState - the window state to use when opening the permissions configuration dialog. For more information, see LiferayWindowState.
roleTypes - the role types
request - the current request
Returns:
the URL for opening the resource's permissions configuration dialog and for configuring the resource's permissions
Throws:
Exception - if an exception occurred

doEndTag

public int doEndTag()
             throws javax.servlet.jsp.JspException
Specified by:
doEndTag in interface javax.servlet.jsp.tagext.Tag
Overrides:
doEndTag in class javax.servlet.jsp.tagext.TagSupport
Throws:
javax.servlet.jsp.JspException

setModelResource

public void setModelResource(String modelResource)

setModelResourceDescription

public void setModelResourceDescription(String modelResourceDescription)

setRedirect

public void setRedirect(String redirect)

setResourceGroupId

public void setResourceGroupId(Object resourceGroupId)

setResourcePrimKey

public void setResourcePrimKey(String resourcePrimKey)

setRoleTypes

public void setRoleTypes(int[] roleTypes)

setVar

public void setVar(String var)

setWindowState

public void setWindowState(String windowState)

Liferay 7.0-ce-b4