This project has retired. For details please refer to its Attic page.
RoleSecurityTagSupport (Tiles 2 2.1.4 API)

org.apache.tiles.jsp.taglib
Class RoleSecurityTagSupport

Package class diagram package RoleSecurityTagSupport
java.lang.Object
  extended by javax.servlet.jsp.tagext.TagSupport
      extended by javax.servlet.jsp.tagext.BodyTagSupport
          extended by org.apache.tiles.jsp.taglib.TilesBodyTag
              extended by org.apache.tiles.jsp.taglib.RoleSecurityTagSupport
All Implemented Interfaces:
Serializable, BodyTag, IterationTag, JspTag, Tag, TryCatchFinally
Direct Known Subclasses:
ContainerTagSupport

Deprecated. Use AddAttributeTag and PutAttributeTag directly.

public abstract class RoleSecurityTagSupport
extends TilesBodyTag

Base tag for the tiles tags which provides standard support for security.

Since:
Tiles 2.0
Version:
$Rev: 734996 $ $Date: 2009-01-16 14:27:28 +0100 (ven, 16 gen 2009) $
See Also:
Serialized Form

Field Summary
 
Fields inherited from class javax.servlet.jsp.tagext.BodyTagSupport
bodyContent
 
Fields inherited from class javax.servlet.jsp.tagext.TagSupport
id, pageContext
 
Fields inherited from interface javax.servlet.jsp.tagext.BodyTag
EVAL_BODY_BUFFERED, EVAL_BODY_TAG
 
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
RoleSecurityTagSupport()
          Deprecated.  
 
Method Summary
 int doEndTag()
          Deprecated. 
protected abstract  void execute()
          Deprecated. Executes the tag.
 String getRole()
          Deprecated. Returns the role to check.
protected  boolean isAccessAllowed()
          Deprecated. Checks if the user is inside the specified role.
protected  void reset()
          Deprecated. Release any per-invocation resources, resetting any resources or state that should be cleared between successive invocations of Tag.doEndTag() and Tag.doStartTag().
 void setRole(String role)
          Deprecated. Sets the role to check.
 
Methods inherited from class org.apache.tiles.jsp.taglib.TilesBodyTag
doCatch, doFinally, release
 
Methods inherited from class javax.servlet.jsp.tagext.BodyTagSupport
doAfterBody, doInitBody, doStartTag, getBodyContent, getPreviousOut, setBodyContent
 
Methods inherited from class javax.servlet.jsp.tagext.TagSupport
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
 
Methods inherited from interface javax.servlet.jsp.tagext.Tag
getParent, setPageContext, setParent
 

Constructor Detail

RoleSecurityTagSupport

public RoleSecurityTagSupport()
Deprecated. 
Method Detail

getRole

public String getRole()
Deprecated. 
Returns the role to check. If the user is in the specified role, the tag is taken into account; otherwise, the tag is ignored (skipped).

Returns:
The role to check.

setRole

public void setRole(String role)
Deprecated. 
Sets the role to check. If the user is in the specified role, the tag is taken into account; otherwise, the tag is ignored (skipped).

Parameters:
role - The role to check.

reset

protected void reset()
Deprecated. 
Release any per-invocation resources, resetting any resources or state that should be cleared between successive invocations of Tag.doEndTag() and Tag.doStartTag().

Overrides:
reset in class TilesBodyTag

doEndTag

public int doEndTag()
             throws TilesJspException
Deprecated. 

Specified by:
doEndTag in interface Tag
Overrides:
doEndTag in class BodyTagSupport
Throws:
TilesJspException

execute

protected abstract void execute()
                         throws TilesJspException,
                                IOException
Deprecated. 
Executes the tag. It is called inside doEndTag().

Throws:
TilesJspException - If something goes wrong during rendering.
IOException - If something goes wrong during writing content.

isAccessAllowed

protected boolean isAccessAllowed()
Deprecated. 
Checks if the user is inside the specified role.

Returns:
true if the user is allowed to have the tag rendered.


Copyright © 2001-2009 Apache Software Foundation. All Rights Reserved.