summaryrefslogtreecommitdiffstats
path: root/applications/guard/src/main
diff options
context:
space:
mode:
Diffstat (limited to 'applications/guard/src/main')
-rw-r--r--applications/guard/src/main/java/org/onap/policy/xacml/pdp/application/guard/GuardPolicyRequest.java4
-rw-r--r--applications/guard/src/main/java/org/onap/policy/xacml/pdp/application/guard/GuardTranslator.java14
2 files changed, 9 insertions, 9 deletions
diff --git a/applications/guard/src/main/java/org/onap/policy/xacml/pdp/application/guard/GuardPolicyRequest.java b/applications/guard/src/main/java/org/onap/policy/xacml/pdp/application/guard/GuardPolicyRequest.java
index 7394ab30..44b4d627 100644
--- a/applications/guard/src/main/java/org/onap/policy/xacml/pdp/application/guard/GuardPolicyRequest.java
+++ b/applications/guard/src/main/java/org/onap/policy/xacml/pdp/application/guard/GuardPolicyRequest.java
@@ -167,7 +167,7 @@ public class GuardPolicyRequest {
return request;
}
- private static GuardPolicyRequest findFields(GuardPolicyRequest request, Map<String, Object> guard)
+ protected static GuardPolicyRequest findFields(GuardPolicyRequest request, Map<String, Object> guard)
throws ToscaPolicyConversionException {
if (guard.containsKey("actor")) {
request.actorId = guard.get("actor").toString();
@@ -192,7 +192,7 @@ public class GuardPolicyRequest {
return request;
}
- private static GuardPolicyRequest findFilterFields(GuardPolicyRequest request, Map<String, Object> guard) {
+ protected static GuardPolicyRequest findFilterFields(GuardPolicyRequest request, Map<String, Object> guard) {
if (guard.containsKey("generic-vnf.vnf-name")) {
request.vnfName = guard.get("generic-vnf.vnf-name").toString();
}
diff --git a/applications/guard/src/main/java/org/onap/policy/xacml/pdp/application/guard/GuardTranslator.java b/applications/guard/src/main/java/org/onap/policy/xacml/pdp/application/guard/GuardTranslator.java
index fd9bb004..2083e69d 100644
--- a/applications/guard/src/main/java/org/onap/policy/xacml/pdp/application/guard/GuardTranslator.java
+++ b/applications/guard/src/main/java/org/onap/policy/xacml/pdp/application/guard/GuardTranslator.java
@@ -190,7 +190,7 @@ public class GuardTranslator implements ToscaPolicyTranslator {
* @param variable VariableDefinitionType to add
* @param newPolicyType PolicyType that will be updated
*/
- private void addVariableToConditionTypes(VariableReferenceType variable,
+ protected void addVariableToConditionTypes(VariableReferenceType variable,
PolicyType newPolicyType) {
//
// Iterate through the rules
@@ -440,7 +440,7 @@ public class GuardTranslator implements ToscaPolicyTranslator {
return reference;
}
- private Object parseTimestamp(String string) throws ToscaPolicyConversionException {
+ protected Object parseTimestamp(String string) throws ToscaPolicyConversionException {
//
// First see if it is a full datetime object
//
@@ -722,7 +722,7 @@ public class GuardTranslator implements ToscaPolicyTranslator {
}
}
- private String validateFilterPropertyField(Map<String, Object> filterAttributes)
+ protected String validateFilterPropertyField(Map<String, Object> filterAttributes)
throws ToscaPolicyConversionException {
Object field = filterAttributes.get(FIELD_FILTER_FIELD);
if (field != null) {
@@ -741,7 +741,7 @@ public class GuardTranslator implements ToscaPolicyTranslator {
throw new ToscaPolicyConversionException("Missing \'field\' from filter");
}
- private String validateFilterPropertyFilter(Map<String, Object> filterAttributes)
+ protected String validateFilterPropertyFilter(Map<String, Object> filterAttributes)
throws ToscaPolicyConversionException {
Object filter = filterAttributes.get(FIELD_FILTER_FILTER);
if (filter != null) {
@@ -750,7 +750,7 @@ public class GuardTranslator implements ToscaPolicyTranslator {
throw new ToscaPolicyConversionException("Missing \'filter\' from filter");
}
- private Identifier validateFilterPropertyFunction(Map<String, Object> filterAttributes)
+ protected Identifier validateFilterPropertyFunction(Map<String, Object> filterAttributes)
throws ToscaPolicyConversionException {
Object function = filterAttributes.get(FIELD_FILTER_FUNCTION);
if (function != null) {
@@ -782,7 +782,7 @@ public class GuardTranslator implements ToscaPolicyTranslator {
throw new ToscaPolicyConversionException("Missing \'function\' from filter");
}
- private boolean validateFilterPropertyBlacklist(Map<String, Object> filterAttributes)
+ protected boolean validateFilterPropertyBlacklist(Map<String, Object> filterAttributes)
throws ToscaPolicyConversionException {
Object filter = filterAttributes.get(FIELD_FILTER_BLACKLIST);
if (filter != null) {
@@ -797,7 +797,7 @@ public class GuardTranslator implements ToscaPolicyTranslator {
throw new ToscaPolicyConversionException("Missing \'blacklist\' from filter");
}
- private RuleType createFilterRule(String ruleId, String field, String filter, Identifier function,
+ protected RuleType createFilterRule(String ruleId, String field, String filter, Identifier function,
boolean isBlacklisted) {
RuleType rule = new RuleType();
rule.setRuleId(ruleId);