summaryrefslogtreecommitdiffstats
path: root/blueprints-processor/plugin/model-provider
diff options
context:
space:
mode:
authorSingal, Kapil (ks220y) <ks220y@att.com>2018-09-21 11:51:07 -0400
committerSingal, Kapil (ks220y) <ks220y@att.com>2018-09-21 12:26:03 -0400
commit9b4060cdaf1d56d14fcf16417a3ec19bcb45cf87 (patch)
tree34f85695d2167cdc6734fedddb61be832f136189 /blueprints-processor/plugin/model-provider
parentb01c3ea880b504e2adc2f1ab676d82201f619bf7 (diff)
SDN Controller Blueprints Processor
Changing java beans for Resource Definition Dictionaries as per new Schema Change-Id: I38f7a7433a4d31a4e5a21af193261c53d64c5750 Issue-ID: CCSDK-490 Signed-off-by: Singal, Kapil (ks220y) <ks220y@att.com>
Diffstat (limited to 'blueprints-processor/plugin/model-provider')
-rw-r--r--blueprints-processor/plugin/model-provider/src/main/java/org/onap/ccsdk/features/model/data/dict/ResourceDefinition.java26
-rw-r--r--blueprints-processor/plugin/model-provider/src/main/java/org/onap/ccsdk/features/model/data/dict/SourcesDefinition.java2
-rw-r--r--blueprints-processor/plugin/model-provider/src/main/java/org/onap/ccsdk/features/model/data/dict/SourcesProperties.java36
-rw-r--r--blueprints-processor/plugin/model-provider/src/test/java/org/onap/ccsdk/features/model/ResourceDictionaryUtilsTest.java1
-rw-r--r--blueprints-processor/plugin/model-provider/src/test/java/org/onap/ccsdk/features/model/utils/JsonParserUtilsTest.java1
-rw-r--r--blueprints-processor/plugin/model-provider/src/test/java/org/onap/ccsdk/features/model/utils/JsonUtilsTest.java1
-rw-r--r--blueprints-processor/plugin/model-provider/src/test/java/org/onap/ccsdk/features/model/utils/ResourceAssignmentUtilsTest.java1
-rw-r--r--blueprints-processor/plugin/model-provider/src/test/java/org/onap/ccsdk/features/model/utils/ServiceTemplateUtilsTest.java1
-rw-r--r--blueprints-processor/plugin/model-provider/src/test/java/org/onap/ccsdk/features/model/utils/TransformationUtilsTest.java1
-rw-r--r--blueprints-processor/plugin/model-provider/src/test/java/org/onap/ccsdk/features/model/validator/ServiceTemplateValidationTest.java1
10 files changed, 24 insertions, 47 deletions
diff --git a/blueprints-processor/plugin/model-provider/src/main/java/org/onap/ccsdk/features/model/data/dict/ResourceDefinition.java b/blueprints-processor/plugin/model-provider/src/main/java/org/onap/ccsdk/features/model/data/dict/ResourceDefinition.java
index 7a49979a5..25605fcd2 100644
--- a/blueprints-processor/plugin/model-provider/src/main/java/org/onap/ccsdk/features/model/data/dict/ResourceDefinition.java
+++ b/blueprints-processor/plugin/model-provider/src/main/java/org/onap/ccsdk/features/model/data/dict/ResourceDefinition.java
@@ -24,23 +24,19 @@ import com.fasterxml.jackson.annotation.JsonProperty;
@JsonIgnoreProperties(ignoreUnknown = true)
public class ResourceDefinition {
- private String tags;
@JsonProperty(value = "name", required = true)
private String name;
+ @JsonProperty(value = "tags")
+ private String tags;
+
@JsonProperty(value = "property")
private PropertyDefinition property;
@JsonProperty(value = "updated-by")
private String updatedBy;
- @JsonProperty(value = "resource-type", required = true)
- private String resourceType;
-
- @JsonProperty(value = "resource-path", required = true)
- private String resourcePath;
-
@JsonProperty(value = "sources", required = true)
private Map<String, SourcesDefinition> sourcesDefinition;
@@ -76,22 +72,6 @@ public class ResourceDefinition {
this.updatedBy = updatedBy;
}
- public String getResourceType() {
- return resourceType;
- }
-
- public void setResourceType(String resourceType) {
- this.resourceType = resourceType;
- }
-
- public String getResourcePath() {
- return resourcePath;
- }
-
- public void setResourcePath(String resourcePath) {
- this.resourcePath = resourcePath;
- }
-
public Map<String, SourcesDefinition> getSources() {
return sourcesDefinition;
}
diff --git a/blueprints-processor/plugin/model-provider/src/main/java/org/onap/ccsdk/features/model/data/dict/SourcesDefinition.java b/blueprints-processor/plugin/model-provider/src/main/java/org/onap/ccsdk/features/model/data/dict/SourcesDefinition.java
index 8ba4471e3..0ce7eda37 100644
--- a/blueprints-processor/plugin/model-provider/src/main/java/org/onap/ccsdk/features/model/data/dict/SourcesDefinition.java
+++ b/blueprints-processor/plugin/model-provider/src/main/java/org/onap/ccsdk/features/model/data/dict/SourcesDefinition.java
@@ -17,8 +17,10 @@
package org.onap.ccsdk.features.model.data.dict;
+import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
import com.fasterxml.jackson.annotation.JsonProperty;
+@JsonIgnoreProperties(ignoreUnknown = true)
public class SourcesDefinition {
@JsonProperty(value = "type", required = true)
diff --git a/blueprints-processor/plugin/model-provider/src/main/java/org/onap/ccsdk/features/model/data/dict/SourcesProperties.java b/blueprints-processor/plugin/model-provider/src/main/java/org/onap/ccsdk/features/model/data/dict/SourcesProperties.java
index 2a57617ec..696e1516d 100644
--- a/blueprints-processor/plugin/model-provider/src/main/java/org/onap/ccsdk/features/model/data/dict/SourcesProperties.java
+++ b/blueprints-processor/plugin/model-provider/src/main/java/org/onap/ccsdk/features/model/data/dict/SourcesProperties.java
@@ -19,15 +19,14 @@ package org.onap.ccsdk.features.model.data.dict;
import java.util.List;
import java.util.Map;
+import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
import com.fasterxml.jackson.annotation.JsonProperty;
+@JsonIgnoreProperties(ignoreUnknown = true)
public class SourcesProperties {
- @JsonProperty(value = "name")
- private String name;
-
- @JsonProperty(value = "base")
- private String base;
+ @JsonProperty(value = "key")
+ private String key;
@JsonProperty(value = "type")
private String type;
@@ -38,6 +37,9 @@ public class SourcesProperties {
@JsonProperty(value = "url-path")
private String urlPath;
+ @JsonProperty(value = "expression-type")
+ private String expressionType;
+
@JsonProperty(value = "path")
private String path;
@@ -50,20 +52,12 @@ public class SourcesProperties {
@JsonProperty("key-dependencies")
private List<String> dependencies;
- public String getName() {
- return name;
- }
-
- public void setName(String name) {
- this.name = name;
- }
-
- public String getBase() {
- return base;
+ public String getKey() {
+ return key;
}
- public void setBase(String base) {
- this.base = base;
+ public void setKey(String key) {
+ this.key = key;
}
public String getType() {
@@ -94,6 +88,14 @@ public class SourcesProperties {
return path;
}
+ public void setExpressionType(String expressionType) {
+ this.expressionType = expressionType;
+ }
+
+ public String getExpressionType() {
+ return expressionType;
+ }
+
public void setPath(String path) {
this.path = path;
}
diff --git a/blueprints-processor/plugin/model-provider/src/test/java/org/onap/ccsdk/features/model/ResourceDictionaryUtilsTest.java b/blueprints-processor/plugin/model-provider/src/test/java/org/onap/ccsdk/features/model/ResourceDictionaryUtilsTest.java
index 9965f61c6..760c245fd 100644
--- a/blueprints-processor/plugin/model-provider/src/test/java/org/onap/ccsdk/features/model/ResourceDictionaryUtilsTest.java
+++ b/blueprints-processor/plugin/model-provider/src/test/java/org/onap/ccsdk/features/model/ResourceDictionaryUtilsTest.java
@@ -21,7 +21,6 @@ import java.util.Arrays;
import java.util.HashMap;
import org.junit.Assert;
import org.junit.Test;
-import org.onap.ccsdk.features.model.ValidTypes;
import org.onap.ccsdk.features.model.data.PropertyDefinition;
import org.onap.ccsdk.features.model.data.ResourceAssignment;
import org.onap.ccsdk.features.model.data.dict.ResourceDefinition;
diff --git a/blueprints-processor/plugin/model-provider/src/test/java/org/onap/ccsdk/features/model/utils/JsonParserUtilsTest.java b/blueprints-processor/plugin/model-provider/src/test/java/org/onap/ccsdk/features/model/utils/JsonParserUtilsTest.java
index 1875f115d..8ff1ff8de 100644
--- a/blueprints-processor/plugin/model-provider/src/test/java/org/onap/ccsdk/features/model/utils/JsonParserUtilsTest.java
+++ b/blueprints-processor/plugin/model-provider/src/test/java/org/onap/ccsdk/features/model/utils/JsonParserUtilsTest.java
@@ -19,7 +19,6 @@ package org.onap.ccsdk.features.model.utils;
import org.junit.Assert;
import org.junit.Test;
-import org.onap.ccsdk.features.model.utils.JsonParserUtils;
import com.fasterxml.jackson.databind.JsonNode;
public class JsonParserUtilsTest {
diff --git a/blueprints-processor/plugin/model-provider/src/test/java/org/onap/ccsdk/features/model/utils/JsonUtilsTest.java b/blueprints-processor/plugin/model-provider/src/test/java/org/onap/ccsdk/features/model/utils/JsonUtilsTest.java
index 9cc3fc681..96d5f89f5 100644
--- a/blueprints-processor/plugin/model-provider/src/test/java/org/onap/ccsdk/features/model/utils/JsonUtilsTest.java
+++ b/blueprints-processor/plugin/model-provider/src/test/java/org/onap/ccsdk/features/model/utils/JsonUtilsTest.java
@@ -20,7 +20,6 @@ package org.onap.ccsdk.features.model.utils;
import static org.junit.Assert.assertTrue;
import org.junit.Test;
import org.onap.ccsdk.features.model.ValidTypes;
-import org.onap.ccsdk.features.model.utils.JsonUtils;
import com.fasterxml.jackson.databind.node.ArrayNode;
import com.fasterxml.jackson.databind.node.JsonNodeFactory;
import com.fasterxml.jackson.databind.node.ObjectNode;
diff --git a/blueprints-processor/plugin/model-provider/src/test/java/org/onap/ccsdk/features/model/utils/ResourceAssignmentUtilsTest.java b/blueprints-processor/plugin/model-provider/src/test/java/org/onap/ccsdk/features/model/utils/ResourceAssignmentUtilsTest.java
index 01548b648..60ef24049 100644
--- a/blueprints-processor/plugin/model-provider/src/test/java/org/onap/ccsdk/features/model/utils/ResourceAssignmentUtilsTest.java
+++ b/blueprints-processor/plugin/model-provider/src/test/java/org/onap/ccsdk/features/model/utils/ResourceAssignmentUtilsTest.java
@@ -30,7 +30,6 @@ import org.onap.ccsdk.features.model.ValidTypes;
import org.onap.ccsdk.features.model.data.PropertyDefinition;
import org.onap.ccsdk.features.model.data.ResourceAssignment;
import org.onap.ccsdk.features.model.data.dict.ResourceDefinition;
-import org.onap.ccsdk.features.model.utils.ResourceAssignmentUtils;
import com.fasterxml.jackson.core.type.TypeReference;
import com.fasterxml.jackson.databind.JsonNode;
import com.fasterxml.jackson.databind.ObjectMapper;
diff --git a/blueprints-processor/plugin/model-provider/src/test/java/org/onap/ccsdk/features/model/utils/ServiceTemplateUtilsTest.java b/blueprints-processor/plugin/model-provider/src/test/java/org/onap/ccsdk/features/model/utils/ServiceTemplateUtilsTest.java
index df330b69e..525dda4e1 100644
--- a/blueprints-processor/plugin/model-provider/src/test/java/org/onap/ccsdk/features/model/utils/ServiceTemplateUtilsTest.java
+++ b/blueprints-processor/plugin/model-provider/src/test/java/org/onap/ccsdk/features/model/utils/ServiceTemplateUtilsTest.java
@@ -24,7 +24,6 @@ import org.junit.Test;
import org.onap.ccsdk.features.model.data.ArtifactDefinition;
import org.onap.ccsdk.features.model.data.CapabilityAssignment;
import org.onap.ccsdk.features.model.data.NodeTemplate;
-import org.onap.ccsdk.features.model.utils.ServiceTemplateUtils;
public class ServiceTemplateUtilsTest {
diff --git a/blueprints-processor/plugin/model-provider/src/test/java/org/onap/ccsdk/features/model/utils/TransformationUtilsTest.java b/blueprints-processor/plugin/model-provider/src/test/java/org/onap/ccsdk/features/model/utils/TransformationUtilsTest.java
index feb6321d2..f73bc1af2 100644
--- a/blueprints-processor/plugin/model-provider/src/test/java/org/onap/ccsdk/features/model/utils/TransformationUtilsTest.java
+++ b/blueprints-processor/plugin/model-provider/src/test/java/org/onap/ccsdk/features/model/utils/TransformationUtilsTest.java
@@ -22,7 +22,6 @@ import static org.junit.Assert.assertTrue;
import java.util.HashMap;
import java.util.Map;
import org.junit.Test;
-import org.onap.ccsdk.features.model.utils.TransformationUtils;
import com.fasterxml.jackson.databind.JsonNode;
public class TransformationUtilsTest {
diff --git a/blueprints-processor/plugin/model-provider/src/test/java/org/onap/ccsdk/features/model/validator/ServiceTemplateValidationTest.java b/blueprints-processor/plugin/model-provider/src/test/java/org/onap/ccsdk/features/model/validator/ServiceTemplateValidationTest.java
index a95f301f0..72a49ebc7 100644
--- a/blueprints-processor/plugin/model-provider/src/test/java/org/onap/ccsdk/features/model/validator/ServiceTemplateValidationTest.java
+++ b/blueprints-processor/plugin/model-provider/src/test/java/org/onap/ccsdk/features/model/validator/ServiceTemplateValidationTest.java
@@ -20,7 +20,6 @@ package org.onap.ccsdk.features.model.validator;
import java.nio.charset.Charset;
import org.apache.commons.io.IOUtils;
import org.junit.Test;
-import org.onap.ccsdk.features.model.validator.ServiceTemplateValidator;
import com.att.eelf.configuration.EELFLogger;
import com.att.eelf.configuration.EELFManager;