From 2c3be92eccd45ebad09d4fea7245f11a3c14f583 Mon Sep 17 00:00:00 2001 From: Munir Ahmad Date: Fri, 2 Mar 2018 19:47:30 -0500 Subject: Replace explicit type with dimond type Change-Id: I1dedb9ef1ca7b734e3cfc0a3a594d733dbd298d4 Issue-ID: SO-437 Signed-off-by: Munir Ahmad --- .../main/java/org/openecomp/mso/openstack/utils/MsoHeatUtils.java | 2 +- .../org/openecomp/mso/openstack/utils/MsoHeatUtilsWithUpdate.java | 4 ++-- .../java/org/openecomp/mso/openstack/utils/MsoKeystoneUtils.java | 4 ++-- .../java/org/openecomp/mso/openstack/utils/MsoNeutronUtils.java | 6 +++--- 4 files changed, 8 insertions(+), 8 deletions(-) (limited to 'adapters/mso-adapter-utils/src/main/java/org/openecomp') diff --git a/adapters/mso-adapter-utils/src/main/java/org/openecomp/mso/openstack/utils/MsoHeatUtils.java b/adapters/mso-adapter-utils/src/main/java/org/openecomp/mso/openstack/utils/MsoHeatUtils.java index 46cfbf1bb8..c438d0a277 100644 --- a/adapters/mso-adapter-utils/src/main/java/org/openecomp/mso/openstack/utils/MsoHeatUtils.java +++ b/adapters/mso-adapter-utils/src/main/java/org/openecomp/mso/openstack/utils/MsoHeatUtils.java @@ -1436,7 +1436,7 @@ public class MsoHeatUtils extends MsoCommonUtils { if (inputs == null) { LOGGER.debug("convertInputMap - inputs is null - nothing to do here"); - return new HashMap(); + return new HashMap<>(); } LOGGER.debug("convertInputMap in MsoHeatUtils called, with " + inputs.size() + " inputs, and template " + template.getArtifactUuid()); diff --git a/adapters/mso-adapter-utils/src/main/java/org/openecomp/mso/openstack/utils/MsoHeatUtilsWithUpdate.java b/adapters/mso-adapter-utils/src/main/java/org/openecomp/mso/openstack/utils/MsoHeatUtilsWithUpdate.java index 0e0b9cb70d..f7e67d87f8 100644 --- a/adapters/mso-adapter-utils/src/main/java/org/openecomp/mso/openstack/utils/MsoHeatUtilsWithUpdate.java +++ b/adapters/mso-adapter-utils/src/main/java/org/openecomp/mso/openstack/utils/MsoHeatUtilsWithUpdate.java @@ -230,7 +230,7 @@ public class MsoHeatUtilsWithUpdate extends MsoHeatUtils { if (haveFiles && haveHeatFiles) { // Let's do this here - not in the bean LOGGER.debug ("Found files AND heatFiles - combine and add!"); - Map combinedFiles = new HashMap (); + Map combinedFiles = new HashMap<>(); for (String keyString : files.keySet ()) { combinedFiles.put (keyString, files.get (keyString)); } @@ -358,7 +358,7 @@ public class MsoHeatUtilsWithUpdate extends MsoHeatUtils { sb.append("(outputs is empty)"); return sb; } - Map outputs = new HashMap(); + Map outputs = new HashMap<>(); for (Output outputItem : outputList) { outputs.put(outputItem.getOutputKey(), outputItem.getOutputValue()); } diff --git a/adapters/mso-adapter-utils/src/main/java/org/openecomp/mso/openstack/utils/MsoKeystoneUtils.java b/adapters/mso-adapter-utils/src/main/java/org/openecomp/mso/openstack/utils/MsoKeystoneUtils.java index 714684aba6..3b710032c1 100644 --- a/adapters/mso-adapter-utils/src/main/java/org/openecomp/mso/openstack/utils/MsoKeystoneUtils.java +++ b/adapters/mso-adapter-utils/src/main/java/org/openecomp/mso/openstack/utils/MsoKeystoneUtils.java @@ -209,7 +209,7 @@ public class MsoKeystoneUtils extends MsoTenantUtils { return null; } - Map metadata = new HashMap (); + Map metadata = new HashMap<>(); if (cloudSite.getIdentityService ().hasTenantMetadata ()) { OpenStackRequest request = keystoneAdminClient.tenants ().showMetadata (tenant.getId ()); Metadata tenantMetadata = executeAndRecordOpenstackRequest (request, msoProps); @@ -255,7 +255,7 @@ public class MsoKeystoneUtils extends MsoTenantUtils { return null; } - Map metadata = new HashMap (); + Map metadata = new HashMap<>(); if (cloudSite.getIdentityService ().hasTenantMetadata ()) { OpenStackRequest request = keystoneAdminClient.tenants ().showMetadata (tenant.getId ()); Metadata tenantMetadata = executeAndRecordOpenstackRequest (request, msoProps); diff --git a/adapters/mso-adapter-utils/src/main/java/org/openecomp/mso/openstack/utils/MsoNeutronUtils.java b/adapters/mso-adapter-utils/src/main/java/org/openecomp/mso/openstack/utils/MsoNeutronUtils.java index c65a715b66..9eba799e18 100644 --- a/adapters/mso-adapter-utils/src/main/java/org/openecomp/mso/openstack/utils/MsoNeutronUtils.java +++ b/adapters/mso-adapter-utils/src/main/java/org/openecomp/mso/openstack/utils/MsoNeutronUtils.java @@ -63,7 +63,7 @@ public class MsoNeutronUtils extends MsoCommonUtils // token will be used until it expires. // // The cache key is "tenantId:cloudId" - private static Map neutronClientCache = new HashMap(); + private static Map neutronClientCache = new HashMap<>(); // Fetch cloud configuration each time (may be cached in CloudConfig class) private CloudConfig cloudConfig; @@ -129,7 +129,7 @@ public class MsoNeutronUtils extends MsoCommonUtils } } else if (type == NetworkType.MULTI_PROVIDER) { if (provider != null && vlans != null && vlans.size() > 0) { - List segments = new ArrayList(vlans.size()); + List segments = new ArrayList<>(vlans.size()); for (int vlan : vlans) { Segment segment = new Segment(); segment.setProviderPhysicalNetwork (provider); @@ -297,7 +297,7 @@ public class MsoNeutronUtils extends MsoCommonUtils } } else if (type == NetworkType.MULTI_PROVIDER) { if (provider != null && vlans != null && vlans.size() > 0) { - List segments = new ArrayList(vlans.size()); + List segments = new ArrayList<>(vlans.size()); for (int vlan : vlans) { Segment segment = new Segment(); segment.setProviderPhysicalNetwork (provider); -- cgit 1.2.3-korg