net.sf.jguard.jee.taglib
Class Authorized

java.lang.Object
  extended by javax.servlet.jsp.tagext.TagSupport
      extended by javax.servlet.jsp.jstl.core.ConditionalTagSupport
          extended by net.sf.jguard.jee.taglib.Authorized
All Implemented Interfaces:
Serializable, javax.servlet.jsp.tagext.IterationTag, javax.servlet.jsp.tagext.Tag

public class Authorized
extends javax.servlet.jsp.jstl.core.ConditionalTagSupport

display the jsp fragment if the user has got the right to access to the ressource protected by the permission.

Author:
Charles Gay
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
Authorized()
           
 
Method Summary
protected  boolean condition()
          allow or not to display jsp content;depends on access rights.
 String getPermission()
           
 String getUri()
           
 void setPermission(String permission)
           
 void setUri(String strUri)
           
 
Methods inherited from class javax.servlet.jsp.jstl.core.ConditionalTagSupport
doStartTag, release, setScope, setVar
 
Methods inherited from class javax.servlet.jsp.tagext.TagSupport
doAfterBody, doEndTag, findAncestorWithClass, getId, getParent, getValue, getValues, 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

Authorized

public Authorized()
Method Detail

getUri

public String getUri()
Returns:
uri

setUri

public void setUri(String strUri)
Parameters:
strUri -

condition

protected boolean condition()
                     throws javax.servlet.jsp.JspTagException
allow or not to display jsp content;depends on access rights.

Specified by:
condition in class javax.servlet.jsp.jstl.core.ConditionalTagSupport
Returns:
true if tag displays content when user is authorized; false otherwise
Throws:
javax.servlet.jsp.JspTagException
See Also:
ConditionalTagSupport.condition()

getPermission

public String getPermission()

setPermission

public void setPermission(String permission)


Copyright © 2004-2011. All Rights Reserved.