com.caucho.server.security
Class RoleConstraint
java.lang.Object
com.caucho.server.security.AbstractConstraint
com.caucho.server.security.RoleConstraint
public class RoleConstraint
- extends AbstractConstraint
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
RoleConstraint
public RoleConstraint()
addRoleName
public void addRoleName(java.lang.String role)
needsAuthentication
public boolean needsAuthentication()
- Returns true if the constraint requires authentication.
- Overrides:
needsAuthentication in class AbstractConstraint
isAuthorized
public boolean isAuthorized(HttpServletRequest request,
HttpServletResponse response,
ServletContext application)
throws ServletException,
java.io.IOException
- Returns true if the user is authorized for the resource.
- Specified by:
isAuthorized in class AbstractConstraint
- Parameters:
request - the servlet requestresponse - the servlet response
- Returns:
- true if the request is authorized.
- Throws:
ServletException
java.io.IOException
toString
public java.lang.String toString()
- Overrides:
toString in class java.lang.Object