1 package org.onap.vid.policy;
3 import com.fasterxml.jackson.annotation.JsonInclude;
4 import com.fasterxml.jackson.annotation.JsonProperty;
5 import com.fasterxml.jackson.annotation.JsonPropertyOrder;
6 import org.apache.commons.lang.builder.ToStringBuilder;
9 * This wrapper encapsulates the Policy response
11 @JsonInclude(JsonInclude.Include.NON_NULL)
17 public class PolicyResponseWrapper {
19 @JsonProperty("status")
22 @JsonProperty("entity")
23 private String entity;
25 @JsonProperty("entity")
26 public String getEntity() {
30 @JsonProperty("status")
31 public int getStatus() {
35 @JsonProperty("status")
36 public void setStatus(int v) {
40 @JsonProperty("entity")
41 public void setEntity(String v) {
46 public String toString() {
47 return ToStringBuilder.reflectionToString(this);
50 public String getResponse () {
52 StringBuilder b = new StringBuilder ("{ \"status\": ");
53 b.append(getStatus()).append(", \"entity\": " ).append(this.getEntity()).append("}");
54 return (b.toString());