From d932a21e9f99ef5e706975a73c4f17a145445fe1 Mon Sep 17 00:00:00 2001 From: eleonorali Date: Mon, 11 Jun 2018 18:18:32 +0300 Subject: CR Port Mirroring: add new properties Add new properties nfc_naming_code and nf_naming_code. Merge from release/1806. Change-Id: I25abd4036e34ab43980ec433df9a3510926e4f8b Issue-ID: SDC-1417 Signed-off-by: eleonorali --- .../impl/tosca/PortMirroringEnricher.java | 2 +- .../PortMirroringConnectionPointDescription.java | 23 ++++++++++++++++++++++ 2 files changed, 24 insertions(+), 1 deletion(-) (limited to 'openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java') diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/impl/tosca/PortMirroringEnricher.java b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/impl/tosca/PortMirroringEnricher.java index c95274d7fe..669fb1c0ee 100644 --- a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/impl/tosca/PortMirroringEnricher.java +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/impl/tosca/PortMirroringEnricher.java @@ -248,7 +248,7 @@ public class PortMirroringEnricher { if (requirementAssignment.isPresent()) { RequirementAssignment bindingRequirementAssignment = requirementAssignment.get().get(0); String node = bindingRequirementAssignment.getNode(); - connectionPoint.setNfc_type(node); + connectionPoint.setNfc_naming_code(node); } } diff --git a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/impl/tosca/model/PortMirroringConnectionPointDescription.java b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/impl/tosca/model/PortMirroringConnectionPointDescription.java index c166938d2d..1c54e01743 100644 --- a/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/impl/tosca/model/PortMirroringConnectionPointDescription.java +++ b/openecomp-be/lib/openecomp-sdc-enrichment-lib/openecomp-sdc-enrichment-impl/src/main/java/org/openecomp/sdc/enrichment/impl/tosca/model/PortMirroringConnectionPointDescription.java @@ -6,6 +6,9 @@ import java.util.Objects; public class PortMirroringConnectionPointDescription { private String nf_type; private String nfc_type; + private String nf_naming_code; + private String nfc_naming_code; + //Keeping below attributes as objects to accomodate for tosca functions for property // values like get_input, get_attribute private Object network_role; @@ -15,6 +18,8 @@ public class PortMirroringConnectionPointDescription { //Populating empty strings as default values to be populated in tosca nf_type = ""; nfc_type = ""; + nf_naming_code = ""; + nfc_naming_code = ""; network_role = ""; pps_capacity = ""; } @@ -35,6 +40,22 @@ public class PortMirroringConnectionPointDescription { this.nfc_type = nfc_type; } + public String getNf_naming_code() { + return nf_naming_code; + } + + public void setNf_naming_code(String nf_naming_code) { + this.nf_naming_code = nf_naming_code; + } + + public String getNfc_naming_code() { + return nfc_naming_code; + } + + public void setNfc_naming_code(String nfc_naming_code) { + this.nfc_naming_code = nfc_naming_code; + } + public Object getNetwork_role() { return network_role; } @@ -54,6 +75,8 @@ public class PortMirroringConnectionPointDescription { public boolean isEmpty() { return Objects.isNull(nf_type) && Objects.isNull(nfc_type) + && Objects.isNull(nf_naming_code) + && Objects.isNull(nfc_naming_code) && Objects.isNull(network_role) && Objects.isNull(pps_capacity); } -- cgit 1.2.3-korg