Package com.sun.xacml.finder

Examples of com.sun.xacml.finder.PolicyFinderResult


   /**
    * @see PolicyFinderModule#findPolicy(com.sun.xacml.EvaluationCtx)
    */
   public PolicyFinderResult findPolicy(EvaluationCtx evaluationCtx)
   {
      return new PolicyFinderResult(policy);
   }
View Full Code Here


    *        com.sun.xacml.VersionConstraints, com.sun.xacml.PolicyMetaData)
    */
   public PolicyFinderResult findPolicy(URI arg0, int arg1,
         VersionConstraints arg2, PolicyMetaData arg3)
   {
      return new PolicyFinderResult(policy);
   }
View Full Code Here

        MatchResult match = policySet.match(context);
        int result = match.getResult();

            // if target matching was indeterminate, then return the error
            if (result == MatchResult.INDETERMINATE)
                return new PolicyFinderResult(match.getStatus());

         // see if the target matched
            if (result == MatchResult.MATCH) {
                // see if we previously found another match
                if (selectedPolicy != null) {
                    // we found a match before, so this is an error
                    ArrayList code = new ArrayList();
                    code.add(Status.STATUS_PROCESSING_ERROR);
                    Status status = new Status(code, "too many applicable "
                                               + "top-level policies");
                    return new PolicyFinderResult(status);
                }

                // this is the first match we've found, so remember it
                selectedPolicy = policySet;
            }


        // return the single applicable policy (if there was one)
        return new PolicyFinderResult(selectedPolicy);
    }
View Full Code Here

      VersionConstraints constraints, PolicyMetaData parentMetaData)
  {
    for(Policy p:policies)
    {
      if(p.getId().compareTo(idReference) == 0)
        return new PolicyFinderResult(p);
    }
    return new PolicyFinderResult();
  }
View Full Code Here

   /**
    * @see PolicyFinderModule#findPolicy(com.sun.xacml.EvaluationCtx)
    */
   public PolicyFinderResult findPolicy(EvaluationCtx evaluationCtx)
   {
      return new PolicyFinderResult(policy);
   }
View Full Code Here

    *        com.sun.xacml.VersionConstraints, com.sun.xacml.PolicyMetaData)
    */
   public PolicyFinderResult findPolicy(URI arg0, int arg1,
         VersionConstraints arg2, PolicyMetaData arg3)
   {
      return new PolicyFinderResult(policy);
   }
View Full Code Here

      aList.add(Status.STATUS_SYNTAX_ERROR);
     
       try
       {
          if(this.encounteredParsingException)
             return new PolicyFinderResult(new Status(aList));
           AbstractPolicy policy = policies.getPolicy(context);

           if (policy == null)
               return new PolicyFinderResult();
           else
               return new PolicyFinderResult(policy);
       }
       catch (TopLevelPolicyException tlpe)
       {
           return new PolicyFinderResult(tlpe.getStatus());
       }
   }
View Full Code Here

/* 57 */     this.policyFinder = policyFinder;
/*    */   }
/*    */
/*    */   public PolicyFinderResult findPolicy(EvaluationCtx evaluationCtx)
/*    */   {
/* 65 */     return new PolicyFinderResult(this.policy);
/*    */   }
View Full Code Here

/* 65 */     return new PolicyFinderResult(this.policy);
/*    */   }
/*    */
/*    */   public PolicyFinderResult findPolicy(URI arg0, int arg1, VersionConstraints arg2, PolicyMetaData arg3)
/*    */   {
/* 75 */     return new PolicyFinderResult(this.policy);
/*    */   }
View Full Code Here

/* 264 */     List aList = new ArrayList();
/* 265 */     aList.add("urn:oasis:names:tc:xacml:1.0:status:syntax-error");
/*     */     try
/*     */     {
/* 269 */       if (this.encounteredParsingException)
/* 270 */         return new PolicyFinderResult(new Status(aList));
/* 271 */       AbstractPolicy policy = this.policies.getPolicy(context);
/*     */
/* 273 */       if (policy == null) {
/* 274 */         return new PolicyFinderResult();
/*     */       }
/* 276 */       return new PolicyFinderResult(policy);
/*     */     }
/*     */     catch (TopLevelPolicyException tlpe) {
/*     */     }
/* 280 */     return new PolicyFinderResult(tlpe.getStatus());
/*     */   }
View Full Code Here

TOP

Related Classes of com.sun.xacml.finder.PolicyFinderResult

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.