org.mentawai.tag.authorization
Class RequiresAuthorization

java.lang.Object
  extended by javax.servlet.jsp.tagext.TagSupport
      extended by org.mentawai.tag.authorization.RequiresAuthorization
All Implemented Interfaces:
Serializable, javax.servlet.jsp.tagext.IterationTag, javax.servlet.jsp.tagext.JspTag, javax.servlet.jsp.tagext.Tag

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

Author:
Sergio Oliveira
See Also:
Serialized Form

Field Summary
protected  Action action
           
protected  ApplicationManager appManager
           
protected  Locale loc
           
protected  javax.servlet.http.HttpServletRequest req
           
protected  javax.servlet.http.HttpServletResponse res
           
protected  javax.servlet.http.HttpSession session
           
 
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
RequiresAuthorization()
           
 
Method Summary
 int doEndTag()
          Verify if the parameters of the groups or permissions exist or are not denied for the user
 int doStartTag()
           
 void setBoth(boolean both)
          If you want both options to be valid set true for this value If you want any options to be valid set false for this value
 void setCache(boolean cache)
           
 void setGroup(String group)
           
 void setGroups(String groups)
           
 void setPermission(String permission)
           
 void setPermissions(String permissions)
           
 
Methods inherited from class javax.servlet.jsp.tagext.TagSupport
doAfterBody, 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
 

Field Detail

session

protected javax.servlet.http.HttpSession session

req

protected javax.servlet.http.HttpServletRequest req

res

protected javax.servlet.http.HttpServletResponse res

action

protected Action action

loc

protected Locale loc

appManager

protected ApplicationManager appManager
Constructor Detail

RequiresAuthorization

public RequiresAuthorization()
Method Detail

setCache

public void setCache(boolean cache)

setBoth

public void setBoth(boolean both)
If you want both options to be valid set true for this value If you want any options to be valid set false for this value

Parameters:
both -

setGroups

public void setGroups(String groups)

setGroup

public void setGroup(String group)

setPermission

public void setPermission(String permission)

setPermissions

public void setPermissions(String permissions)

doStartTag

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

doEndTag

public int doEndTag()
             throws javax.servlet.jsp.JspException
Verify if the parameters of the groups or permissions exist or are not denied for the user

Specified by:
doEndTag in interface javax.servlet.jsp.tagext.Tag
Overrides:
doEndTag in class javax.servlet.jsp.tagext.TagSupport
Returns:
int
Throws:
javax.servlet.jsp.JspException


Copyright © 2013. All Rights Reserved.