summaryrefslogtreecommitdiffstats
path: root/dcaedt_catalog/service/src/main/java/org/onap/sdc/dcae/catalog/engine/CatalogResponse.java
diff options
context:
space:
mode:
Diffstat (limited to 'dcaedt_catalog/service/src/main/java/org/onap/sdc/dcae/catalog/engine/CatalogResponse.java')
-rw-r--r--dcaedt_catalog/service/src/main/java/org/onap/sdc/dcae/catalog/engine/CatalogResponse.java39
1 files changed, 39 insertions, 0 deletions
diff --git a/dcaedt_catalog/service/src/main/java/org/onap/sdc/dcae/catalog/engine/CatalogResponse.java b/dcaedt_catalog/service/src/main/java/org/onap/sdc/dcae/catalog/engine/CatalogResponse.java
new file mode 100644
index 0000000..2f9913f
--- /dev/null
+++ b/dcaedt_catalog/service/src/main/java/org/onap/sdc/dcae/catalog/engine/CatalogResponse.java
@@ -0,0 +1,39 @@
+package org.onap.sdc.dcae.catalog.engine;
+
+
+import com.fasterxml.jackson.annotation.JsonRawValue;
+
+import org.json.JSONObject;
+import org.onap.sdc.dcae.catalog.engine.CatalogMessage;
+import org.onap.sdc.dcae.catalog.engine.CatalogRequest;
+
+/**
+ */
+public class CatalogResponse extends CatalogMessage {
+
+ private JSONObject data = new JSONObject(),
+ error = new JSONObject();
+
+ public CatalogResponse(CatalogRequest theRequest) {
+ setId(theRequest.getId());
+ setTimestamp(theRequest.getTimestamp());
+ }
+
+ public JSONObject data() {
+ return this.data;
+ }
+
+ @JsonRawValue
+ public String getData() {
+ return this.data.toString();
+ }
+
+ public JSONObject error() {
+ return this.error;
+ }
+
+ @JsonRawValue
+ public String getError() {
+ return this.error.toString();
+ }
+}