| 
 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
The class Condition defines an interface 
 to allow pluggable condition. These are used to control 
 policy decisions based on parameters such as time,
 authentication level of the user session and IP address from which
 the user is making the request.
 A condition computes a ConditionDecision based on the state
 of condition object as  set by setProperties method call and 
 the environment passed in a map of key/value pairs. 
 ConditionDecision encapsulates  whether a policy applies for 
 the request and advice messages  generated by the condition.
 The following Condition implementation are provided with the 
 Policy framework:
 AuthLevelCondition, AuthSchemeCondition,
 IPCondition, TimeCondition
 All condition implementations should have a public no argument 
 constructor.
ConditionDecision| Method Summary | |
|  java.lang.Object | clone()Returns a copy of this object. | 
|  ConditionDecision | getConditionDecision(SSOToken token,
                     java.util.Map env)Gets the decision computed by this condition object, based on the map of environment parameters | 
|  java.lang.String | getDisplayName(java.lang.String property,
               java.util.Locale locale)Gets the display name for the property name. | 
|  java.util.Map | getProperties()Gets the properties of the condition | 
|  java.util.List | getPropertyNames()Returns a list of property names for the condition. | 
|  Syntax | getPropertySyntax(java.lang.String property)Returns the syntax for a property name | 
|  java.util.Set | getValidValues(java.lang.String property)Returns a set of valid values given the property name. | 
|  void | setProperties(java.util.Map properties)Sets the properties of the condition. | 
| Method Detail | 
public java.util.List getPropertyNames()
public Syntax getPropertySyntax(java.lang.String property)
property - property nameSyntax for the property name- See Also: 
- Syntax
public java.lang.String getDisplayName(java.lang.String property,
                                       java.util.Locale locale)
                                throws PolicyException
locale variable could be used by the plugin to
 customize the display name for the given locale.
 The locale variable could be null, in which
 case the plugin must use the default locale.property - property namelocale - locale for which the property name must be customizedPolicyException -  
public java.util.Set getValidValues(java.lang.String property)
                             throws PolicyException
property - property namePolicyException - if unable to get the Syntax.
public void setProperties(java.util.Map properties)
                   throws PolicyException
ConditionDecision that would be
  computed by a call to method getConditionDecision(Map) and
  the advice messages generated included in the
  ConditionDecision.
  ConditionDecision encapsulates whether a policy applies for
  the request and advice messages generated by the condition.
  For example, for a TimeCondition, the properties would
  define StartTime and EndTime, to define
  the time range during which the policy appliesproperties - the properties of the condition 
         that would influence the ConditionDecision returned
         by a call to method getConditionDecision(Map).
         Keys of the properties have to be String.
         Value corresponding to each key have to be a Set of String 
         elements. Each implementation of Condition could add further
         restrictions on the keys and values of this map.PolicyException - for any abnormal conditionConditionDecisionpublic java.util.Map getProperties()
setProperties(java.util.Map)
public ConditionDecision getConditionDecision(SSOToken token,
                                              java.util.Map env)
                                       throws PolicyException,
                                              SSOException
token - single-sign-on token of the userenv - request specific environment map of key/value pairs
        For example this would contain IP address of remote
        client for an IPCondition.ConditionDecision.
 Otherwise, further evaluation  of the policy is skipped. However, the
 advice messages encapsulated  in the ConditionDecision
 are aggregated and passed up, encapsulated in  the policy  decision.PolicyException - if the decision could not be computedSSOException - if SSO token is not validConditionDecisionpublic java.lang.Object clone()
| 
 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||