diff options
author | Stone, Avi (as206k) <as206k@att.com> | 2018-05-24 16:12:32 +0300 |
---|---|---|
committer | Stone, Avi (as206k) <as206k@att.com> | 2018-05-24 16:12:32 +0300 |
commit | 1a0189f890e4ff65ee245be9b7ef67788ac53a61 (patch) | |
tree | 15c269d48d03ef35770763169bd85f4cf31398c0 /dcaedt_catalog/commons | |
parent | cd0441658018dfbab0950f959c9b718ad9601f6d (diff) |
Update code
Update to latest version after improving testing and sonar coverage
Change-Id: I527f4bc38d3b4e1005d38e3a2584fa730857425d
Issue-ID: SDC-1313
Signed-off-by: Stone, Avi (as206k) <as206k@att.com>
Diffstat (limited to 'dcaedt_catalog/commons')
4 files changed, 5 insertions, 10 deletions
diff --git a/dcaedt_catalog/commons/src/main/java/org/onap/sdc/dcae/catalog/commons/Action.java b/dcaedt_catalog/commons/src/main/java/org/onap/sdc/dcae/catalog/commons/Action.java index fb36950..2c62412 100644 --- a/dcaedt_catalog/commons/src/main/java/org/onap/sdc/dcae/catalog/commons/Action.java +++ b/dcaedt_catalog/commons/src/main/java/org/onap/sdc/dcae/catalog/commons/Action.java @@ -1,7 +1,5 @@ package org.onap.sdc.dcae.catalog.commons; -import org.onap.sdc.dcae.catalog.commons.Future; - /** */ public interface Action<T> { diff --git a/dcaedt_catalog/commons/src/main/java/org/onap/sdc/dcae/catalog/commons/Future.java b/dcaedt_catalog/commons/src/main/java/org/onap/sdc/dcae/catalog/commons/Future.java index c50f467..61a0a11 100644 --- a/dcaedt_catalog/commons/src/main/java/org/onap/sdc/dcae/catalog/commons/Future.java +++ b/dcaedt_catalog/commons/src/main/java/org/onap/sdc/dcae/catalog/commons/Future.java @@ -1,8 +1,5 @@ package org.onap.sdc.dcae.catalog.commons; -import org.onap.sdc.dcae.catalog.commons.Future; -import org.onap.sdc.dcae.catalog.commons.FutureHandler; - /** * Modeled after the vertx future */ diff --git a/dcaedt_catalog/commons/src/main/java/org/onap/sdc/dcae/catalog/commons/FutureHandler.java b/dcaedt_catalog/commons/src/main/java/org/onap/sdc/dcae/catalog/commons/FutureHandler.java index b689412..738a6cf 100644 --- a/dcaedt_catalog/commons/src/main/java/org/onap/sdc/dcae/catalog/commons/FutureHandler.java +++ b/dcaedt_catalog/commons/src/main/java/org/onap/sdc/dcae/catalog/commons/FutureHandler.java @@ -1,7 +1,5 @@ package org.onap.sdc.dcae.catalog.commons; -import org.onap.sdc.dcae.catalog.commons.Future; - /** * Modeled after the vertx future */ diff --git a/dcaedt_catalog/commons/src/main/java/org/onap/sdc/dcae/catalog/commons/Futures.java b/dcaedt_catalog/commons/src/main/java/org/onap/sdc/dcae/catalog/commons/Futures.java index a405932..1773fdd 100644 --- a/dcaedt_catalog/commons/src/main/java/org/onap/sdc/dcae/catalog/commons/Futures.java +++ b/dcaedt_catalog/commons/src/main/java/org/onap/sdc/dcae/catalog/commons/Futures.java @@ -115,10 +115,12 @@ public class Futures<T> { BasicHandler<T> hnd = buildHandler(); setHandler(hnd); hnd.waitForCompletion(); - if (failed()) - throw (Exception)cause(); - else + if (failed()) { + throw (Exception) cause(); + } + else { return result(); + } } public Future<T> waitForCompletion() throws InterruptedException { |