summaryrefslogtreecommitdiffstats
path: root/applications/guard
diff options
context:
space:
mode:
Diffstat (limited to 'applications/guard')
-rw-r--r--applications/guard/src/main/java/org/onap/policy/xacml/pdp/application/guard/GuardTranslator.java6
1 files changed, 3 insertions, 3 deletions
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 3aae5fc4..45caf21c 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
@@ -129,7 +129,7 @@ public class GuardTranslator implements ToscaPolicyTranslator {
//
// Policy name should be at the root
//
- String policyName = toscaPolicy.getMetadata().get("policy-id");
+ String policyName = String.valueOf(toscaPolicy.getMetadata().get("policy-id"));
//
// Set it as the policy ID
//
@@ -275,14 +275,14 @@ public class GuardTranslator implements ToscaPolicyTranslator {
* @param map The Metadata TOSCA Map
* @return Same Policy Object
*/
- protected PolicyType fillMetadataSection(PolicyType policy, Map<String, String> map) {
+ protected PolicyType fillMetadataSection(PolicyType policy, Map<String, Object> map) {
//
// NOTE: The models code ensures the metadata section ALWAYS exists
//
//
// Add in the Policy Version
//
- policy.setVersion(map.get("policy-version"));
+ policy.setVersion(String.valueOf(map.get("policy-version")));
return policy;
}