Include response in OperationOutcome
[policy/models.git] / models-interactions / model-actors / actorServiceProvider / src / main / java / org / onap / policy / controlloop / actorserviceprovider / OperationOutcome.java
index e2d94b3..0fd2c0b 100644 (file)
@@ -43,6 +43,7 @@ public class OperationOutcome {
     private PolicyResult result = PolicyResult.SUCCESS;
     private String message;
     private boolean finalOutcome;
+    private Object response;
     private ControlLoopResponse controlLoopResponse;
 
     /**
@@ -60,6 +61,7 @@ public class OperationOutcome {
         this.result = source.result;
         this.message = source.message;
         this.finalOutcome = source.finalOutcome;
+        this.response = source.response;
         this.controlLoopResponse = source.controlLoopResponse;
     }
 
@@ -85,6 +87,11 @@ public class OperationOutcome {
         return clo;
     }
 
+    @SuppressWarnings("unchecked")
+    public <T> T getResponse() {
+        return (T) response;
+    }
+
     /**
      * Determines if this outcome is for the given actor and operation.
      *