aboutsummaryrefslogtreecommitdiffstats
path: root/mso-catalog-db/src
diff options
context:
space:
mode:
authorMunir Ahmad <munir.ahmad@bell.ca>2018-03-02 19:47:30 -0500
committerSeshu Kumar M <seshu.kumar.m@huawei.com>2018-03-06 14:40:52 +0000
commit2c3be92eccd45ebad09d4fea7245f11a3c14f583 (patch)
treeb18a696ea61d917e332b19157ffcd2b66f6e4cb1 /mso-catalog-db/src
parent9f4a5beffd747c5e816f97d8c04d99ceee4a32f3 (diff)
Replace explicit type with dimond type
Change-Id: I1dedb9ef1ca7b734e3cfc0a3a594d733dbd298d4 Issue-ID: SO-437 Signed-off-by: Munir Ahmad <munir.ahmad@bell.ca>
Diffstat (limited to 'mso-catalog-db/src')
-rw-r--r--mso-catalog-db/src/main/java/org/openecomp/mso/db/catalog/CatalogDatabase.java2
-rw-r--r--mso-catalog-db/src/main/java/org/openecomp/mso/db/catalog/beans/ServiceMacroHolder.java2
-rw-r--r--mso-catalog-db/src/main/java/org/openecomp/mso/db/catalog/beans/VnfResource.java8
-rw-r--r--mso-catalog-db/src/main/java/org/openecomp/mso/db/catalog/beans/VnfResourceCustomization.java2
-rw-r--r--mso-catalog-db/src/test/java/org/openecomp/mso/db/catalog/test/CatalogDatabaseTest.java6
-rw-r--r--mso-catalog-db/src/test/java/org/openecomp/mso/db/catalog/test/MavenVersioningTest.java2
6 files changed, 11 insertions, 11 deletions
diff --git a/mso-catalog-db/src/main/java/org/openecomp/mso/db/catalog/CatalogDatabase.java b/mso-catalog-db/src/main/java/org/openecomp/mso/db/catalog/CatalogDatabase.java
index 7cf8c2190c..774953435c 100644
--- a/mso-catalog-db/src/main/java/org/openecomp/mso/db/catalog/CatalogDatabase.java
+++ b/mso-catalog-db/src/main/java/org/openecomp/mso/db/catalog/CatalogDatabase.java
@@ -2693,7 +2693,7 @@ public class CatalogDatabase implements Closeable {
}
private void populateNetworkResourceType(List<NetworkResourceCustomization> resultList) {
- HashMap<String, NetworkResource> networkResources = new HashMap<String, NetworkResource>();
+ HashMap<String, NetworkResource> networkResources = new HashMap<>();
for (NetworkResourceCustomization nrc : resultList) {
String network_id = nrc.getNetworkResourceModelUuid();
diff --git a/mso-catalog-db/src/main/java/org/openecomp/mso/db/catalog/beans/ServiceMacroHolder.java b/mso-catalog-db/src/main/java/org/openecomp/mso/db/catalog/beans/ServiceMacroHolder.java
index 645626d125..78f94e40c1 100644
--- a/mso-catalog-db/src/main/java/org/openecomp/mso/db/catalog/beans/ServiceMacroHolder.java
+++ b/mso-catalog-db/src/main/java/org/openecomp/mso/db/catalog/beans/ServiceMacroHolder.java
@@ -43,7 +43,7 @@ public class ServiceMacroHolder implements Serializable {
public ServiceMacroHolder() {
super();
this.service = null;
- this.vnfResources = new ArrayList<VnfResource>();
+ this.vnfResources = new ArrayList<>();
this.networkResourceCustomizations = new ArrayList<>();
this.allottedResourceCustomizations = new ArrayList<>();
this.vnfResourceCustomizations = new ArrayList<>();
diff --git a/mso-catalog-db/src/main/java/org/openecomp/mso/db/catalog/beans/VnfResource.java b/mso-catalog-db/src/main/java/org/openecomp/mso/db/catalog/beans/VnfResource.java
index f0b990acae..806cbeb076 100644
--- a/mso-catalog-db/src/main/java/org/openecomp/mso/db/catalog/beans/VnfResource.java
+++ b/mso-catalog-db/src/main/java/org/openecomp/mso/db/catalog/beans/VnfResource.java
@@ -195,7 +195,7 @@ public class VnfResource extends MavenLikeVersioning implements Serializable {
}
public List<VfModuleCustomization> getVfModuleCustomizations() {
- return this.vfModuleCustomizations == null ? new ArrayList<VfModuleCustomization>() : this.vfModuleCustomizations;
+ return this.vfModuleCustomizations == null ? new ArrayList<>() : this.vfModuleCustomizations;
}
public void setVfModuleCustomizations(ArrayList<VfModuleCustomization> vfModuleCustomizations) {
this.vfModuleCustomizations = vfModuleCustomizations;
@@ -205,7 +205,7 @@ public class VnfResource extends MavenLikeVersioning implements Serializable {
if (this.vfModuleCustomizations != null) {
this.vfModuleCustomizations.add(vfmc);
} else {
- this.vfModuleCustomizations = new ArrayList<VfModuleCustomization>();
+ this.vfModuleCustomizations = new ArrayList<>();
this.vfModuleCustomizations.add(vfmc);
}
}
@@ -216,7 +216,7 @@ public class VnfResource extends MavenLikeVersioning implements Serializable {
if (this.vfModules != null) {
this.vfModules.add(vfm);
} else {
- this.vfModules = new HashSet<VfModule>();
+ this.vfModules = new HashSet<>();
this.vfModules.add(vfm);
}
}
@@ -225,7 +225,7 @@ public class VnfResource extends MavenLikeVersioning implements Serializable {
if (this.vfModules == null || this.vfModules.size() < 1) {
return null;
}
- ArrayList<VfModule> list = new ArrayList<VfModule>();
+ ArrayList<VfModule> list = new ArrayList<>();
list.addAll(this.vfModules);
return list;
}
diff --git a/mso-catalog-db/src/main/java/org/openecomp/mso/db/catalog/beans/VnfResourceCustomization.java b/mso-catalog-db/src/main/java/org/openecomp/mso/db/catalog/beans/VnfResourceCustomization.java
index 151c9e594e..b211dbd4c3 100644
--- a/mso-catalog-db/src/main/java/org/openecomp/mso/db/catalog/beans/VnfResourceCustomization.java
+++ b/mso-catalog-db/src/main/java/org/openecomp/mso/db/catalog/beans/VnfResourceCustomization.java
@@ -155,7 +155,7 @@ public class VnfResourceCustomization extends MavenLikeVersioning implements Ser
if (this.vfModuleCustomizations != null) {
this.vfModuleCustomizations.add(vfmc);
} else {
- this.vfModuleCustomizations = new ArrayList<VfModuleCustomization>();
+ this.vfModuleCustomizations = new ArrayList<>();
this.vfModuleCustomizations.add(vfmc);
}
}
diff --git a/mso-catalog-db/src/test/java/org/openecomp/mso/db/catalog/test/CatalogDatabaseTest.java b/mso-catalog-db/src/test/java/org/openecomp/mso/db/catalog/test/CatalogDatabaseTest.java
index e9f080b1dd..3cab4f243b 100644
--- a/mso-catalog-db/src/test/java/org/openecomp/mso/db/catalog/test/CatalogDatabaseTest.java
+++ b/mso-catalog-db/src/test/java/org/openecomp/mso/db/catalog/test/CatalogDatabaseTest.java
@@ -2445,7 +2445,7 @@ public class CatalogDatabaseTest {
@Test(expected = Exception.class)
public void saveHeatTemplateTest(){
HeatTemplate heat = new HeatTemplate();
- Set <HeatTemplateParam> paramSet = new HashSet<HeatTemplateParam>();
+ Set <HeatTemplateParam> paramSet = new HashSet<>();
cd.saveHeatTemplate(heat,paramSet);
}
@Test(expected = Exception.class)
@@ -2665,12 +2665,12 @@ public class CatalogDatabaseTest {
@Test(expected = Exception.class)
public void executeQuerySingleRow(){
VnfComponent ar = new VnfComponent();
- HashMap<String, String> variables = new HashMap<String, String>();
+ HashMap<String, String> variables = new HashMap<>();
cd.executeQuerySingleRow("tets",variables,false);
}
@Test(expected = Exception.class)
public void executeQueryMultipleRows(){
- HashMap<String, String> variables = new HashMap<String, String>();
+ HashMap<String, String> variables = new HashMap<>();
cd.executeQueryMultipleRows("select",variables,false);
}
}
diff --git a/mso-catalog-db/src/test/java/org/openecomp/mso/db/catalog/test/MavenVersioningTest.java b/mso-catalog-db/src/test/java/org/openecomp/mso/db/catalog/test/MavenVersioningTest.java
index 5bcadb760b..3dddb17d7c 100644
--- a/mso-catalog-db/src/test/java/org/openecomp/mso/db/catalog/test/MavenVersioningTest.java
+++ b/mso-catalog-db/src/test/java/org/openecomp/mso/db/catalog/test/MavenVersioningTest.java
@@ -153,7 +153,7 @@ public class MavenVersioningTest {
MavenLikeVersioning test12 = new MavenLikeVersioning();
test12.setVersion("2.0");
- List<MavenLikeVersioning> list= new LinkedList<MavenLikeVersioning>();
+ List<MavenLikeVersioning> list= new LinkedList<>();
list.add(test1);
list.add(test2);
list.add(test3);