2 * ============LICENSE_START=======================================================
4 * ================================================================================
5 * Copyright (C) 2019 Wipro Limited Intellectual Property. All rights reserved.
6 * ================================================================================
7 * Licensed under the Apache License, Version 2.0 (the "License");
8 * you may not use this file except in compliance with the License.
9 * You may obtain a copy of the License at
11 * http://www.apache.org/licenses/LICENSE-2.0
13 * Unless required by applicable law or agreed to in writing, software
14 * distributed under the License is distributed on an "AS IS" BASIS,
15 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16 * See the License for the specific language governing permissions and
17 * limitations under the License.
18 * ============LICENSE_END=========================================================
21 package org.onap.policy.controlloop;
23 import com.google.gson.annotations.SerializedName;
25 import java.io.Serializable;
26 import java.util.UUID;
28 public class ControlLoopResponse implements Serializable {
30 private static final long serialVersionUID = 2391252138583119195L;
32 @SerializedName("closedLoopControlName")
33 private String closedLoopControlName;
35 @SerializedName("version")
36 private String version = "1.0.0";
38 @SerializedName("requestID")
39 private UUID requestId;
41 @SerializedName("target")
42 private String target;
44 @SerializedName("from")
47 @SerializedName("policyName")
48 private String policyName;
50 @SerializedName("policyVersion")
51 private String policyVersion;
53 @SerializedName("payload")
54 private String payload;
56 public ControlLoopResponse() {
61 * Construct an instace from an existing instance.
64 * the existing instance
66 public ControlLoopResponse(ControlLoopResponse response) {
67 if (response == null) {
70 this.closedLoopControlName = response.closedLoopControlName;
71 this.requestId = response.requestId;
72 this.target = response.target;
73 this.from = response.from;
74 this.policyName = response.policyName;
75 this.policyVersion = response.policyVersion;
76 this.payload = response.payload;
79 public String getClosedLoopControlName() {
80 return closedLoopControlName;
83 public void setClosedLoopControlName(String closedLoopControlName) {
84 this.closedLoopControlName = closedLoopControlName;
87 public String getVersion() {
91 public void setVersion(String version) {
92 this.version = version;
95 public UUID getRequestId() {
99 public void setRequestId(UUID requestId) {
100 this.requestId = requestId;
103 public String getTarget() {
107 public void setTarget(String target) {
108 this.target = target;
111 public String getFrom() {
115 public void setFrom(String from) {
119 public String getPolicyName() {
123 public void setPolicyName(String policyName) {
124 this.policyName = policyName;
127 public String getPolicyVersion() {
128 return policyVersion;
131 public void setPolicyVersion(String policyVersion) {
132 this.policyVersion = policyVersion;
135 public String getPayload() {
139 public void setPayload(String payload) {
140 this.payload = payload;