Class PolicyDecision


  • @Deprecated
    public class PolicyDecision
    extends Object
    Deprecated.
    since 12.0.0
    The PolicyDecision class represents the result of a policy evaluation.
    • Constructor Detail

      • PolicyDecision

        public PolicyDecision()
        Deprecated.
        Default constructor.
    • Method Detail

      • getActionDecisions

        public Map getActionDecisions()
        Deprecated.
        Gets the Map of action decisions associated with this policy decision. The action name is the key to the Map. The value for each key is an ActionDecision.
        Returns:
        the Map of action decisions associated with this policy decision. The action name is the key to the Map. The value for each key is an ActionDecision.
      • addActionDecision

        public void addActionDecision​(ActionDecision newActionDecision,
                                      String trueValue,
                                      String falseValue)
        Deprecated.
        Add an ActionDecision to the PolicyDecision using the provided trueValue and falseValue These are the rules followed to add action decision: Boolean false value overrides boolean true value. The time to live of boolean false value overrides the time to live of boolean true value. Otherwise, action values are simply aggregated. Time to live is set to the minimum of time to live(s) of all values of the action.
        Parameters:
        newActionDecision - an ActionDecision to be added.
        trueValue - String representing the true value in the action schema.
        falseValue - String representing the false value in the action schema.
      • addActionDecision

        public void addActionDecision​(ActionDecision actionDecision)
        Deprecated.
        Adds an action decision to this object if there is already an existing actionDecision associated with the action name in the param actionDecision, merges the values of the new decision with the existing one, changing the time to live for the decision appropriately.
        Parameters:
        actionDecision - action decision to be added
      • toString

        public String toString()
        Deprecated.
        Gets a String representation of this PolicyDecision
        Overrides:
        toString in class Object
        Returns:
        a String representation of this PolicyDecision
      • toXML

        public String toXML()
        Deprecated.
        Gets an XML representation of this object
        Returns:
        an XML representation of this object
      • parsePolicyDecision

        public static PolicyDecision parsePolicyDecision​(Node policyDecisionNode)
                                                  throws PolicyException
        Deprecated.
        Gets a PolicyDecision given corresponding XML node
        Parameters:
        policyDecisionNode - XML node for the policy decision
        Returns:
        policy decision based on the XML node
        Throws:
        PolicyException
      • getResponseDecisions

        public Map getResponseDecisions()
        Deprecated.
        Gets response decisions associated with this policy decision
        Returns:
        Map representing the response decisions associated with this policy decision
      • setResponseDecisions

        public void setResponseDecisions​(Map responseDecisions)
        Deprecated.
        Sets response decisions associated with this policy decision
        Parameters:
        responseDecisions - A Map representing response decisions associated with this policy decision
      • getResponseAttributes

        public Map getResponseAttributes()
        Deprecated.
        Gets response attributes associated with this policy decision. Response attributes are computed as an aggregation of the return Map(s) of the ResponseProvider objects associated with the policy obtained via the getResponseDecision() call.
        Returns:
        the Map of response attributes associated with this policy decision.
      • setResponseAttributes

        public void setResponseAttributes​(Map responseAttributes)
        Deprecated.
        Sets response attributes associated with this policy decision
        Parameters:
        responseAttributes - Map of attribute value pairs associated with this policy decision.
      • clone

        public Object clone()
        Deprecated.
        Makes a copy of this object
        Overrides:
        clone in class Object
        Returns:
        a copied instance
      • getTimeToLive

        public long getTimeToLive()
        Deprecated.
        Gets the GMT time in milliseconds since epoch when this object is to be treated as expired. That is the policy decision would likely be different after that time. This is computed as a result of SimpleTimeConditions specified in the Policy definition.
        Returns:
        time to live
      • hasAdvices

        public boolean hasAdvices()
        Deprecated.
        Checks wether advices are set in this object
        Returns:
        true, if advices are set, else false