aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorrama-huawei <rama.subba.reddy.s@huawei.com>2017-09-26 17:09:45 +0530
committerRama SubbaReddy <rama.subba.reddy.s@huawei.com>2017-09-27 06:53:07 +0000
commitac87369180c8c3e6f24191e38b521d1b74db2189 (patch)
treebea688d5e7afb89eb81f25be86bf86195eb79644
parent00f6a9c613096e3d4623b8e8486992be727d92da (diff)
Replaced with Diamond symbol
Issue-Id:SO-118 Change-Id: I744c8e8278157aefd001ebc27e35e77e115d3b71 Signed-off-by: rama-huawei <rama.subba.reddy.s@huawei.com>
-rw-r--r--adapters/mso-catalog-db-adapter/src/main/java/org/openecomp/mso/adapters/catalogdb/catalogrest/CatalogQueryExceptionCommon.java2
-rw-r--r--adapters/mso-catalog-db-adapter/src/main/java/org/openecomp/mso/adapters/catalogdb/catalogrest/QueryAllottedResourceCustomization.java10
-rw-r--r--adapters/mso-catalog-db-adapter/src/main/java/org/openecomp/mso/adapters/catalogdb/catalogrest/QueryServiceMacroHolder.java4
3 files changed, 8 insertions, 8 deletions
diff --git a/adapters/mso-catalog-db-adapter/src/main/java/org/openecomp/mso/adapters/catalogdb/catalogrest/CatalogQueryExceptionCommon.java b/adapters/mso-catalog-db-adapter/src/main/java/org/openecomp/mso/adapters/catalogdb/catalogrest/CatalogQueryExceptionCommon.java
index 9f709140ec..a1bc08599b 100644
--- a/adapters/mso-catalog-db-adapter/src/main/java/org/openecomp/mso/adapters/catalogdb/catalogrest/CatalogQueryExceptionCommon.java
+++ b/adapters/mso-catalog-db-adapter/src/main/java/org/openecomp/mso/adapters/catalogdb/catalogrest/CatalogQueryExceptionCommon.java
@@ -40,7 +40,7 @@ public abstract class CatalogQueryExceptionCommon {
public String toJsonString() {
try {
- String jsonString = null;
+ String jsonString;
ObjectMapper mapper = new ObjectMapper();
mapper.enable(SerializationConfig.Feature.WRAP_ROOT_VALUE);
jsonString = mapper.writeValueAsString(this);
diff --git a/adapters/mso-catalog-db-adapter/src/main/java/org/openecomp/mso/adapters/catalogdb/catalogrest/QueryAllottedResourceCustomization.java b/adapters/mso-catalog-db-adapter/src/main/java/org/openecomp/mso/adapters/catalogdb/catalogrest/QueryAllottedResourceCustomization.java
index 75262e3597..9a82ed2c6e 100644
--- a/adapters/mso-catalog-db-adapter/src/main/java/org/openecomp/mso/adapters/catalogdb/catalogrest/QueryAllottedResourceCustomization.java
+++ b/adapters/mso-catalog-db-adapter/src/main/java/org/openecomp/mso/adapters/catalogdb/catalogrest/QueryAllottedResourceCustomization.java
@@ -54,7 +54,7 @@ public class QueryAllottedResourceCustomization extends CatalogQuery {
"\t}";
// "\t}}";
- public QueryAllottedResourceCustomization() { super(); allottedResourceCustomization = new ArrayList<AllottedResourceCustomization>(); }
+ public QueryAllottedResourceCustomization() { super(); allottedResourceCustomization = new ArrayList<>(); }
public QueryAllottedResourceCustomization(List<AllottedResourceCustomization> vlist) { allottedResourceCustomization = vlist; }
public List<AllottedResourceCustomization> getServiceAllottedResources(){ return this.allottedResourceCustomization; }
@@ -62,7 +62,7 @@ public class QueryAllottedResourceCustomization extends CatalogQuery {
@Override
public String toString () {
- StringBuffer buf = new StringBuffer();
+ StringBuilder buf = new StringBuilder();
boolean first = true;
int i = 1;
@@ -76,10 +76,10 @@ public class QueryAllottedResourceCustomization extends CatalogQuery {
@Override
public String JSON2(boolean isArray, boolean isEmbed) {
- StringBuffer buf = new StringBuffer();
+ StringBuilder buf = new StringBuilder();
if (!isEmbed && isArray) buf.append("{ ");
if (isArray) buf.append("\"serviceAllottedResources\": [");
- Map<String, String> valueMap = new HashMap<String, String>();
+ Map<String, String> valueMap = new HashMap<>();
String sep = "";
boolean first = true;
@@ -114,4 +114,4 @@ public class QueryAllottedResourceCustomization extends CatalogQuery {
return buf.toString();
}
-} \ No newline at end of file
+}
diff --git a/adapters/mso-catalog-db-adapter/src/main/java/org/openecomp/mso/adapters/catalogdb/catalogrest/QueryServiceMacroHolder.java b/adapters/mso-catalog-db-adapter/src/main/java/org/openecomp/mso/adapters/catalogdb/catalogrest/QueryServiceMacroHolder.java
index 0e2aa714f6..7373cb1e13 100644
--- a/adapters/mso-catalog-db-adapter/src/main/java/org/openecomp/mso/adapters/catalogdb/catalogrest/QueryServiceMacroHolder.java
+++ b/adapters/mso-catalog-db-adapter/src/main/java/org/openecomp/mso/adapters/catalogdb/catalogrest/QueryServiceMacroHolder.java
@@ -60,7 +60,7 @@ public class QueryServiceMacroHolder extends CatalogQuery {
Service service = serviceMacroHolder.getService();
if (service == null) return "\"serviceResources\": null";
- StringBuffer buf = new StringBuffer();
+ StringBuilder buf = new StringBuilder();
Map<String, String> valueMap = new HashMap<String, String>();
put(valueMap, "SERVICE_MODEL_NAME", service.getModelName()); //getServiceModelName());
@@ -84,4 +84,4 @@ public class QueryServiceMacroHolder extends CatalogQuery {
return buf.toString();
}
-} \ No newline at end of file
+}