summaryrefslogtreecommitdiffstats
path: root/examples/examples-pcvs/src/main
diff options
context:
space:
mode:
authorliamfallon <liam.fallon@ericsson.com>2018-09-13 23:48:50 +0100
committerliamfallon <liam.fallon@ericsson.com>2018-09-13 23:49:32 +0100
commitcd68fc9bae7d6258f77ff59c1431e4f925f61a4c (patch)
tree53054a7c8e8738644785039c3a200c6b23d4b3ed /examples/examples-pcvs/src/main
parent4cfa2e2d98f6877d54da304ef17f096284430908 (diff)
Address sonar/Checkstyle Issues
Sweep through Apex codebase to fix most ceheckstyle and straightforward sonar issues. Issue-ID: POLICY-1034 Change-Id: I149d9a94ad893affc93573e8de5e3304b6bdde2d Signed-off-by: liamfallon <liam.fallon@ericsson.com>
Diffstat (limited to 'examples/examples-pcvs/src/main')
-rw-r--r--examples/examples-pcvs/src/main/java/org/onap/policy/apex/examples/pcvs/model/PcvsDomainModelSaver.java15
1 files changed, 10 insertions, 5 deletions
diff --git a/examples/examples-pcvs/src/main/java/org/onap/policy/apex/examples/pcvs/model/PcvsDomainModelSaver.java b/examples/examples-pcvs/src/main/java/org/onap/policy/apex/examples/pcvs/model/PcvsDomainModelSaver.java
index 42d3d659b..1d8381acd 100644
--- a/examples/examples-pcvs/src/main/java/org/onap/policy/apex/examples/pcvs/model/PcvsDomainModelSaver.java
+++ b/examples/examples-pcvs/src/main/java/org/onap/policy/apex/examples/pcvs/model/PcvsDomainModelSaver.java
@@ -23,6 +23,8 @@ package org.onap.policy.apex.examples.pcvs.model;
import org.onap.policy.apex.model.basicmodel.concepts.ApexException;
import org.onap.policy.apex.model.basicmodel.handling.ApexModelSaver;
import org.onap.policy.apex.model.policymodel.concepts.AxPolicyModel;
+import org.slf4j.ext.XLogger;
+import org.slf4j.ext.XLoggerFactory;
/**
* The Class PcvsDomainModelSaver.
@@ -30,9 +32,12 @@ import org.onap.policy.apex.model.policymodel.concepts.AxPolicyModel;
* @author Sven van der Meer (sven.van.der.meer@ericsson.com)
*/
public final class PcvsDomainModelSaver {
+ // Logger for this class
+ private static final XLogger LOGGER = XLoggerFactory.getXLogger(PcvsDomainModelSaver.class);
/** Private constructor to prevent instantiation. */
- private PcvsDomainModelSaver() {}
+ private PcvsDomainModelSaver() {
+ }
/**
* Write all PCVS models to args[0].
@@ -42,14 +47,14 @@ public final class PcvsDomainModelSaver {
*/
public static void main(final String[] args) throws ApexException {
if (args.length != 2) {
- System.err.println(
- "usage: " + PcvsDomainModelSaver.class.getCanonicalName() + " workingDirectory modelDirectory");
+ LOGGER.error("usage: " + PcvsDomainModelSaver.class.getCanonicalName()
+ + " workingDirectory modelDirectory");
return;
}
final AxPolicyModel pcvsPolicyModel = new PcvsDomainModelFactory().getPcvsVpnSlaSPolicyModel(args[0]);
- final ApexModelSaver<AxPolicyModel> pcvsModelSaver =
- new ApexModelSaver<>(AxPolicyModel.class, pcvsPolicyModel, args[1] + "vpnsla/");
+ final ApexModelSaver<AxPolicyModel> pcvsModelSaver = new ApexModelSaver<>(AxPolicyModel.class, pcvsPolicyModel,
+ args[1] + "vpnsla/");
pcvsModelSaver.apexModelWriteJson();
pcvsModelSaver.apexModelWriteXml();