From 097232ce209034cd2fde61903a04f7ba3391f746 Mon Sep 17 00:00:00 2001 From: sharath reddy Date: Mon, 4 Apr 2022 18:27:44 +0530 Subject: Renamed variables to not match a restricted identifier Issue-ID: CLI-439 report: tested weather-report, execution-list Signed-off-by: sharath reddy Change-Id: I9f66d0aeda50ad7981357ff2030b9a937a211a83 --- .../org/onap/cli/fw/output/OnapCommandResult.java | 24 +++++++++++----------- 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/framework/src/main/java/org/onap/cli/fw/output/OnapCommandResult.java b/framework/src/main/java/org/onap/cli/fw/output/OnapCommandResult.java index fa9bcf02..cba7134d 100644 --- a/framework/src/main/java/org/onap/cli/fw/output/OnapCommandResult.java +++ b/framework/src/main/java/org/onap/cli/fw/output/OnapCommandResult.java @@ -120,8 +120,8 @@ public class OnapCommandResult { public Map getRecordsMap() { Map recordMap = new HashMap<>(); - for (OnapCommandResultAttribute record : this.getRecords()) { - recordMap.put(record.getName(), record); + for (OnapCommandResultAttribute data : this.getRecords()) { + recordMap.put(data.getName(), data); } return recordMap; @@ -194,8 +194,8 @@ public class OnapCommandResult { if (!this.getRecords().isEmpty()) { if (this.getPrintDirection().equals(OnapCommandPrintDirection.LANDSCAPE)) { - for (OnapCommandResultAttribute record : this.getScopedRecords()) { - print.addColumn(record.getName(), record.getValues()); + for (OnapCommandResultAttribute data : this.getScopedRecords()) { + print.addColumn(data.getName(), data.getValues()); } } else { // Add property column @@ -207,12 +207,12 @@ public class OnapCommandResult { val.setName(OnapCommandConstants.PORTRAINT_COLUMN_NAME_VALUE); val.setScope(OnapCommandResultAttributeScope.SHORT); - for (OnapCommandResultAttribute record : this.getScopedRecords()) { - prp.getValues().add(record.getName()); - if (record.getValues().size() == 1) { - val.getValues().add(record.getValues().get(0)); + for (OnapCommandResultAttribute data : this.getScopedRecords()) { + prp.getValues().add(data.getName()); + if (data.getValues().size() == 1) { + val.getValues().add(data.getValues().get(0)); } else { - val.getValues().add(record.getValues().toString()); + val.getValues().add(data.getValues().toString()); } } @@ -254,11 +254,11 @@ public class OnapCommandResult { private List getScopedRecords() { List recordList = new ArrayList<>(); - for (OnapCommandResultAttribute record : this.getRecords()) { - if (record.getScope().ordinal() > this.getScope().ordinal()) { + for (OnapCommandResultAttribute data : this.getRecords()) { + if (data.getScope().ordinal() > this.getScope().ordinal()) { continue; } - recordList.add(record); + recordList.add(data); } return recordList; -- cgit 1.2.3-korg