summaryrefslogtreecommitdiffstats
path: root/common-be/src/main/java
diff options
context:
space:
mode:
authoraribeiro <anderson.ribeiro@est.tech>2021-07-15 09:18:37 +0100
committeraribeiro <anderson.ribeiro@est.tech>2021-08-06 17:22:20 +0100
commit47bcc63a9daff1f310125fed006f27c93656fa83 (patch)
tree3c61670b039c0e63d14880f909e6047d54776492 /common-be/src/main/java
parent0ed125f98ae8ea9e80c855a640c328654660d081 (diff)
Retrieve data types based on component model
Issue-ID: SDC-3660 Signed-off-by: aribeiro <anderson.ribeiro@est.tech> Change-Id: I09c533eb39277532b29e581e4dd57e9df952e8e6
Diffstat (limited to 'common-be/src/main/java')
-rw-r--r--common-be/src/main/java/org/openecomp/sdc/be/datatypes/elements/AttributeDataDefinition.java2
-rw-r--r--common-be/src/main/java/org/openecomp/sdc/be/datatypes/elements/DataTypeDataDefinition.java2
-rw-r--r--common-be/src/main/java/org/openecomp/sdc/be/datatypes/elements/PropertyDataDefinition.java11
3 files changed, 10 insertions, 5 deletions
diff --git a/common-be/src/main/java/org/openecomp/sdc/be/datatypes/elements/AttributeDataDefinition.java b/common-be/src/main/java/org/openecomp/sdc/be/datatypes/elements/AttributeDataDefinition.java
index cffab12f90..ee78821b23 100644
--- a/common-be/src/main/java/org/openecomp/sdc/be/datatypes/elements/AttributeDataDefinition.java
+++ b/common-be/src/main/java/org/openecomp/sdc/be/datatypes/elements/AttributeDataDefinition.java
@@ -40,6 +40,7 @@ public class AttributeDataDefinition extends ToscaDataDefinition {
private String outputPath;
private String instanceUniqueId;
private String attributeId;
+ private String model;
private String parentUniqueId;
public AttributeDataDefinition(final AttributeDataDefinition attributeDataDefinition) {
@@ -57,6 +58,7 @@ public class AttributeDataDefinition extends ToscaDataDefinition {
this.setOutputPath(attributeDataDefinition.getOutputPath());
this.setInstanceUniqueId(attributeDataDefinition.getInstanceUniqueId());
this.setAttributeId(attributeDataDefinition.getAttributeId());
+ this.setModel(attributeDataDefinition.getModel());
this.setParentUniqueId(attributeDataDefinition.getParentUniqueId());
this.setOutputId(attributeDataDefinition.getOutputId());
if (CollectionUtils.isNotEmpty(attributeDataDefinition.getGetOutputValues())) {
diff --git a/common-be/src/main/java/org/openecomp/sdc/be/datatypes/elements/DataTypeDataDefinition.java b/common-be/src/main/java/org/openecomp/sdc/be/datatypes/elements/DataTypeDataDefinition.java
index 7baf8c8f3f..51f710ba04 100644
--- a/common-be/src/main/java/org/openecomp/sdc/be/datatypes/elements/DataTypeDataDefinition.java
+++ b/common-be/src/main/java/org/openecomp/sdc/be/datatypes/elements/DataTypeDataDefinition.java
@@ -38,6 +38,7 @@ public class DataTypeDataDefinition extends ToscaDataDefinition {
// "boolean", "string", "float", "integer", "version" })
private String derivedFromName;
private String description;
+ private String model;
/**
* Timestamp of data type creation
*/
@@ -55,5 +56,6 @@ public class DataTypeDataDefinition extends ToscaDataDefinition {
this.description = p.description;
this.creationTime = p.creationTime;
this.modificationTime = p.modificationTime;
+ this.model = p.model;
}
}
diff --git a/common-be/src/main/java/org/openecomp/sdc/be/datatypes/elements/PropertyDataDefinition.java b/common-be/src/main/java/org/openecomp/sdc/be/datatypes/elements/PropertyDataDefinition.java
index 871492c4bd..969d986c4d 100644
--- a/common-be/src/main/java/org/openecomp/sdc/be/datatypes/elements/PropertyDataDefinition.java
+++ b/common-be/src/main/java/org/openecomp/sdc/be/datatypes/elements/PropertyDataDefinition.java
@@ -20,9 +20,7 @@
package org.openecomp.sdc.be.datatypes.elements;
-import org.apache.commons.collections.CollectionUtils;
-import org.openecomp.sdc.be.datatypes.enums.JsonPresentationFields;
-import org.openecomp.sdc.be.datatypes.tosca.ToscaDataDefinition;
+import static org.apache.commons.collections.CollectionUtils.isNotEmpty;
import java.util.ArrayList;
import java.util.HashMap;
@@ -32,9 +30,10 @@ import java.util.Map;
import java.util.Set;
import lombok.Data;
import lombok.EqualsAndHashCode;
-
+import org.apache.commons.collections.CollectionUtils;
import org.apache.commons.collections.MapUtils;
-import static org.apache.commons.collections.CollectionUtils.isNotEmpty;
+import org.openecomp.sdc.be.datatypes.enums.JsonPresentationFields;
+import org.openecomp.sdc.be.datatypes.tosca.ToscaDataDefinition;
import org.openecomp.sdc.be.datatypes.tosca.ToscaGetFunctionType;
@EqualsAndHashCode(callSuper = false)
@@ -62,6 +61,7 @@ public class PropertyDataDefinition extends ToscaDataDefinition {
private String status;
private String inputId;
private String instanceUniqueId;
+ private String model;
private String propertyId;
private String parentPropertyType;
private String subPropertyInputPath;
@@ -109,6 +109,7 @@ public class PropertyDataDefinition extends ToscaDataDefinition {
this.setStatus(propertyDataDefinition.getStatus());
this.setInputId(propertyDataDefinition.getInputId());
this.setInstanceUniqueId(propertyDataDefinition.getInstanceUniqueId());
+ this.setModel(propertyDataDefinition.getModel());
this.setPropertyId(propertyDataDefinition.getPropertyId());
this.setToscaGetFunctionType(propertyDataDefinition.getToscaGetFunctionType());
this.parentPropertyType = propertyDataDefinition.getParentPropertyType();