summaryrefslogtreecommitdiffstats
path: root/dcaedt_catalog/service/src/main/java/org/onap/sdc/dcae/catalog/engine/CatalogError.java
diff options
context:
space:
mode:
authorStone, Avi (as206k) <as206k@att.com>2018-04-12 15:46:31 +0300
committerStone, Avi (as206k) <as206k@att.com>2018-04-12 15:49:38 +0300
commit5032434b101f25fa44d2e1f8dc8393e30af1ed4f (patch)
tree2dc7d37a8048e025c7412af080640da4c9a22b65 /dcaedt_catalog/service/src/main/java/org/onap/sdc/dcae/catalog/engine/CatalogError.java
parent2205633792f95f46a02bbf8f87f0c2637265d924 (diff)
DCAE-D be initial commit
DCAE-D be initial commit Issue-ID: SDC-1218 Change-Id: Id18ba96c499e785aa9ac395fbaf32d57f08c281b Signed-off-by: Stone, Avi (as206k) <as206k@att.com>
Diffstat (limited to 'dcaedt_catalog/service/src/main/java/org/onap/sdc/dcae/catalog/engine/CatalogError.java')
-rw-r--r--dcaedt_catalog/service/src/main/java/org/onap/sdc/dcae/catalog/engine/CatalogError.java20
1 files changed, 20 insertions, 0 deletions
diff --git a/dcaedt_catalog/service/src/main/java/org/onap/sdc/dcae/catalog/engine/CatalogError.java b/dcaedt_catalog/service/src/main/java/org/onap/sdc/dcae/catalog/engine/CatalogError.java
new file mode 100644
index 0000000..0c7c418
--- /dev/null
+++ b/dcaedt_catalog/service/src/main/java/org/onap/sdc/dcae/catalog/engine/CatalogError.java
@@ -0,0 +1,20 @@
+package org.onap.sdc.dcae.catalog.engine;
+
+import org.onap.sdc.dcae.catalog.engine.CatalogRequest;
+import org.onap.sdc.dcae.catalog.engine.CatalogResponse;
+
+/**
+ */
+public class CatalogError extends CatalogResponse {
+
+ public CatalogError(CatalogRequest theRequest, String theMessage) {
+ super(theRequest);
+ error().put("message", theMessage);
+ }
+
+ public CatalogError(CatalogRequest theRequest, String theMessage, Throwable theError) {
+ super(theRequest);
+ error().put("message", theMessage)
+ .put("exception", theError.toString());
+ }
+}