diff options
Diffstat (limited to 'ONAP-XACML/src/main/java')
4 files changed, 5 insertions, 7 deletions
diff --git a/ONAP-XACML/src/main/java/org/onap/policy/xacml/std/pap/StdEngine.java b/ONAP-XACML/src/main/java/org/onap/policy/xacml/std/pap/StdEngine.java index d43a89000..3173bc16d 100644 --- a/ONAP-XACML/src/main/java/org/onap/policy/xacml/std/pap/StdEngine.java +++ b/ONAP-XACML/src/main/java/org/onap/policy/xacml/std/pap/StdEngine.java @@ -625,16 +625,16 @@ public class StdEngine extends StdPDPItemSetChangeNotifier implements PAPPolicyE List<String> ids = new ArrayList<>(); for (PDPGroup group : this.groups) { ids.add(group.getId()); - properties.setProperty(group.getId() + ".name", (group.getName() == null ? "" : group.getName())); - properties.setProperty(group.getId() + ".description", (group.getDescription() == null ? "" : group.getDescription())); + properties.setProperty(group.getId() + ".name", group.getName() == null ? "" : group.getName()); + properties.setProperty(group.getId() + ".description", group.getDescription() == null ? "" : group.getDescription()); // // Iterate its PDPs // List<String> pdps = new ArrayList<>(); for (PDP pdp : group.getPdps()) { pdps.add(pdp.getId()); - properties.setProperty(pdp.getId() + ".name", (pdp.getName() == null ? "" : pdp.getName())); - properties.setProperty(pdp.getId() + ".description", (pdp.getDescription() == null ? "" : pdp.getDescription())); + properties.setProperty(pdp.getId() + ".name", pdp.getName() == null ? "" : pdp.getName()); + properties.setProperty(pdp.getId() + ".description", pdp.getDescription() == null ? "" : pdp.getDescription()); if (pdp instanceof OnapPDP) { properties.setProperty(pdp.getId() + ".jmxport", (((OnapPDP)pdp).getJmxPort()==0 ? "" : ((OnapPDP)pdp).getJmxPort()).toString()); } diff --git a/ONAP-XACML/src/main/java/org/onap/policy/xacml/std/pap/StdPAPPolicy.java b/ONAP-XACML/src/main/java/org/onap/policy/xacml/std/pap/StdPAPPolicy.java index 21381c1a2..c66d11b8c 100644 --- a/ONAP-XACML/src/main/java/org/onap/policy/xacml/std/pap/StdPAPPolicy.java +++ b/ONAP-XACML/src/main/java/org/onap/policy/xacml/std/pap/StdPAPPolicy.java @@ -21,7 +21,6 @@ package org.onap.policy.xacml.std.pap; import java.io.Serializable; import java.net.URI; -import java.util.ArrayList; import java.util.HashMap; import java.util.List; import java.util.Map; diff --git a/ONAP-XACML/src/main/java/org/onap/policy/xacml/std/pap/StdPDPGroup.java b/ONAP-XACML/src/main/java/org/onap/policy/xacml/std/pap/StdPDPGroup.java index 745a43dca..9289c2461 100644 --- a/ONAP-XACML/src/main/java/org/onap/policy/xacml/std/pap/StdPDPGroup.java +++ b/ONAP-XACML/src/main/java/org/onap/policy/xacml/std/pap/StdPDPGroup.java @@ -47,7 +47,6 @@ import org.onap.policy.xacml.std.pap.StdPDPItemSetChangeNotifier.StdItemSetChang import com.att.research.xacml.api.pap.PAPException; import com.att.research.xacml.api.pap.PDP; -//import com.att.research.xacml.api.pap.PDPGroup; import com.att.research.xacml.api.pap.PDPGroupStatus; import com.att.research.xacml.api.pap.PDPGroupStatus.Status; import com.att.research.xacml.api.pap.PDPPIPConfig; diff --git a/ONAP-XACML/src/main/java/org/onap/policy/xacml/util/XACMLPolicyWriter.java b/ONAP-XACML/src/main/java/org/onap/policy/xacml/util/XACMLPolicyWriter.java index 5e60e3730..0807f758b 100644 --- a/ONAP-XACML/src/main/java/org/onap/policy/xacml/util/XACMLPolicyWriter.java +++ b/ONAP-XACML/src/main/java/org/onap/policy/xacml/util/XACMLPolicyWriter.java @@ -252,7 +252,7 @@ public class XACMLPolicyWriter { txtFileName = txtFileName.substring(0, txtFileName.lastIndexOf(".")+1) + origExtension; txtFileName = configUrl+ File.separator + "Config" + File.separator + domain + txtFileName; attributeValueType1.getContent().add(txtFileName); - } else if (attributeAssignmentExpressionType.getAttributeId().equals("PolicyName")) { + } else if ("PolicyName".equals(attributeAssignmentExpressionType.getAttributeId())) { JAXBElement<AttributeValueType> attributeValueType = (JAXBElement<AttributeValueType>) attributeAssignmentExpressionType.getExpression(); AttributeValueType attributeValueType1 = attributeValueType.getValue(); List<Object> contents = attributeValueType1.getContent(); |