rewrite-config-servlet 2.0.0.Alpha2

org.ocpsoft.rewrite.servlet.config
Class JAASRoles

java.lang.Object
  extended by org.ocpsoft.rewrite.config.DefaultConditionBuilder
      extended by org.ocpsoft.rewrite.servlet.config.HttpCondition
          extended by org.ocpsoft.rewrite.servlet.config.JAASRoles
All Implemented Interfaces:
Condition, ConditionBuilder, ConfigurationElement

public class JAASRoles
extends HttpCondition

Implementation of Condition that checks the subject's roles using HttpServletRequest.isUserInRole(String)

Author:
Christian Kaltepoth, Lincoln Baxter, III

Method Summary
 boolean evaluateHttp(HttpServletRewrite event, EvaluationContext context)
           
static JAASRoles required(String... roles)
          Create a new JAASRoles condition requiring the given roles in order for evaluation to return true.
 
Methods inherited from class org.ocpsoft.rewrite.servlet.config.HttpCondition
evaluate
 
Methods inherited from class org.ocpsoft.rewrite.config.DefaultConditionBuilder
and, andNot, create, or, orNot, wrap
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

required

public static JAASRoles required(String... roles)
Create a new JAASRoles condition requiring the given roles in order for evaluation to return true.


evaluateHttp

public boolean evaluateHttp(HttpServletRewrite event,
                            EvaluationContext context)
Specified by:
evaluateHttp in class HttpCondition

rewrite-config-servlet 2.0.0.Alpha2

Copyright © 2012 OCPsoft. All Rights Reserved.