java.lang.Object
javax.servlet.jsp.tagext.TagSupport
jreceiver.client.common.taglibs.RoleAuthIsAuthorizedTag
- All Implemented Interfaces:
- javax.servlet.jsp.tagext.IterationTag, javax.servlet.jsp.tagext.JspTag, java.io.Serializable, javax.servlet.jsp.tagext.Tag
- public class RoleAuthIsAuthorizedTag
- extends javax.servlet.jsp.tagext.TagSupport
JSP Tag isAuthorized, used to determine whether
the user has authorization to access the handler/method.
Example usage:
<jrclient:isAuthorized handler="Playlists" method="getRecs">
<b>Do I have access?</b>
</jrclient:isAuthorized>
TODO: should the user be cached in the RoleAuthBean???
Adapted from JSTL's Request tag.
| Methods inherited from class javax.servlet.jsp.tagext.TagSupport |
doAfterBody, doEndTag, 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 |
m_handler_name
private java.lang.String m_handler_name
m_method_name
private java.lang.String m_method_name
RoleAuthIsAuthorizedTag
public RoleAuthIsAuthorizedTag()
isAuthorized
public static boolean isAuthorized(javax.servlet.jsp.PageContext pageContext,
java.lang.String handler_name,
java.lang.String method_name)
throws jreceiver.common.rpc.RpcException
- test whether the user (in session) is in the specified role
doStartTag
public final int doStartTag()
throws javax.servlet.jsp.JspException
- Determines whether remote user is in a role.
setHandler
public final void setHandler(java.lang.String handler_name)
setMethod
public final void setMethod(java.lang.String method_name)