summaryrefslogtreecommitdiffstats
path: root/bpmn/MSOCoreBPMN
diff options
context:
space:
mode:
Diffstat (limited to 'bpmn/MSOCoreBPMN')
-rw-r--r--bpmn/MSOCoreBPMN/src/main/java/org/openecomp/mso/bpmn/core/domain/JsonWrapper.java8
-rw-r--r--bpmn/MSOCoreBPMN/src/main/java/org/openecomp/mso/bpmn/core/json/JsonWrapper.java10
2 files changed, 5 insertions, 13 deletions
diff --git a/bpmn/MSOCoreBPMN/src/main/java/org/openecomp/mso/bpmn/core/domain/JsonWrapper.java b/bpmn/MSOCoreBPMN/src/main/java/org/openecomp/mso/bpmn/core/domain/JsonWrapper.java
index fbed36548e..f37db4abdd 100644
--- a/bpmn/MSOCoreBPMN/src/main/java/org/openecomp/mso/bpmn/core/domain/JsonWrapper.java
+++ b/bpmn/MSOCoreBPMN/src/main/java/org/openecomp/mso/bpmn/core/domain/JsonWrapper.java
@@ -92,12 +92,10 @@ public abstract class JsonWrapper implements Serializable {
JSONObject json = new JSONObject();
try {
json = new JSONObject(mapper.writeValueAsString(this));
- } catch (JSONException e) {
- LOGGER.debug("Exception :",e);
- } catch (IOException e) {
+ } catch (JSONException | IOException e) {
LOGGER.debug("Exception :",e);
}
- return json;
+ return json;
}
public String listToJson(List list) {
@@ -107,8 +105,6 @@ public abstract class JsonWrapper implements Serializable {
String jsonString = "";
try {
jsonString = mapper.writeValueAsString(list);
- } catch (JsonGenerationException e) {
- LOGGER.debug("Exception :",e);
} catch (IOException e) {
LOGGER.debug("Exception :",e);
}
diff --git a/bpmn/MSOCoreBPMN/src/main/java/org/openecomp/mso/bpmn/core/json/JsonWrapper.java b/bpmn/MSOCoreBPMN/src/main/java/org/openecomp/mso/bpmn/core/json/JsonWrapper.java
index cfa5c853a3..2fe625849b 100644
--- a/bpmn/MSOCoreBPMN/src/main/java/org/openecomp/mso/bpmn/core/json/JsonWrapper.java
+++ b/bpmn/MSOCoreBPMN/src/main/java/org/openecomp/mso/bpmn/core/json/JsonWrapper.java
@@ -85,12 +85,10 @@ public abstract class JsonWrapper implements Serializable {
JSONObject json = new JSONObject();
try {
json = new JSONObject(mapper.writeValueAsString(this));
- } catch (JSONException e) {
+ } catch (JSONException | IOException e) {
LOGGER.debug("Exception :",e);
- } catch (IOException e) {
- LOGGER.debug("Exception :",e);
- }
- return json;
+ }
+ return json;
}
public String listToJson(List list) {
@@ -100,8 +98,6 @@ public abstract class JsonWrapper implements Serializable {
String jsonString = "";
try {
jsonString = mapper.writeValueAsString(list);
- } catch (JsonGenerationException e) {
- LOGGER.debug("Exception :",e);
} catch (IOException e) {
LOGGER.debug("Exception :",e);
}