com.mypurecloud.sdk.v2.model.ErrorDetails Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of platform-client-v2 Show documentation
Show all versions of platform-client-v2 Show documentation
A Java package to interface with the PureCloud Platform API
The newest version!
package com.mypurecloud.sdk.v2.model;
import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonValue;
import com.fasterxml.jackson.core.JsonParser;
import com.fasterxml.jackson.databind.DeserializationContext;
import com.fasterxml.jackson.databind.JsonNode;
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import com.fasterxml.jackson.databind.deser.std.StdDeserializer;
import java.util.Objects;
import java.util.ArrayList;
import java.io.IOException;
import com.fasterxml.jackson.annotation.JsonProperty;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.io.Serializable;
/**
* ErrorDetails
*/
public class ErrorDetails implements Serializable {
private Integer status = null;
private String message = null;
private String messageWithParams = null;
private Map messageParams = null;
private String code = null;
private String contextId = null;
private ErrorDetails nested = null;
private String details = null;
/**
**/
public ErrorDetails status(Integer status) {
this.status = status;
return this;
}
@ApiModelProperty(example = "null", value = "")
@JsonProperty("status")
public Integer getStatus() {
return status;
}
public void setStatus(Integer status) {
this.status = status;
}
/**
**/
public ErrorDetails message(String message) {
this.message = message;
return this;
}
@ApiModelProperty(example = "null", value = "")
@JsonProperty("message")
public String getMessage() {
return message;
}
public void setMessage(String message) {
this.message = message;
}
/**
**/
public ErrorDetails messageWithParams(String messageWithParams) {
this.messageWithParams = messageWithParams;
return this;
}
@ApiModelProperty(example = "null", value = "")
@JsonProperty("messageWithParams")
public String getMessageWithParams() {
return messageWithParams;
}
public void setMessageWithParams(String messageWithParams) {
this.messageWithParams = messageWithParams;
}
/**
**/
public ErrorDetails messageParams(Map messageParams) {
this.messageParams = messageParams;
return this;
}
@ApiModelProperty(example = "null", value = "")
@JsonProperty("messageParams")
public Map getMessageParams() {
return messageParams;
}
public void setMessageParams(Map messageParams) {
this.messageParams = messageParams;
}
/**
**/
public ErrorDetails code(String code) {
this.code = code;
return this;
}
@ApiModelProperty(example = "null", value = "")
@JsonProperty("code")
public String getCode() {
return code;
}
public void setCode(String code) {
this.code = code;
}
/**
**/
public ErrorDetails contextId(String contextId) {
this.contextId = contextId;
return this;
}
@ApiModelProperty(example = "null", value = "")
@JsonProperty("contextId")
public String getContextId() {
return contextId;
}
public void setContextId(String contextId) {
this.contextId = contextId;
}
/**
**/
public ErrorDetails nested(ErrorDetails nested) {
this.nested = nested;
return this;
}
@ApiModelProperty(example = "null", value = "")
@JsonProperty("nested")
public ErrorDetails getNested() {
return nested;
}
public void setNested(ErrorDetails nested) {
this.nested = nested;
}
/**
**/
public ErrorDetails details(String details) {
this.details = details;
return this;
}
@ApiModelProperty(example = "null", value = "")
@JsonProperty("details")
public String getDetails() {
return details;
}
public void setDetails(String details) {
this.details = details;
}
@Override
public boolean equals(java.lang.Object o) {
if (this == o) {
return true;
}
if (o == null || getClass() != o.getClass()) {
return false;
}
ErrorDetails errorDetails = (ErrorDetails) o;
return Objects.equals(this.status, errorDetails.status) &&
Objects.equals(this.message, errorDetails.message) &&
Objects.equals(this.messageWithParams, errorDetails.messageWithParams) &&
Objects.equals(this.messageParams, errorDetails.messageParams) &&
Objects.equals(this.code, errorDetails.code) &&
Objects.equals(this.contextId, errorDetails.contextId) &&
Objects.equals(this.nested, errorDetails.nested) &&
Objects.equals(this.details, errorDetails.details);
}
@Override
public int hashCode() {
return Objects.hash(status, message, messageWithParams, messageParams, code, contextId, nested, details);
}
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class ErrorDetails {\n");
sb.append(" status: ").append(toIndentedString(status)).append("\n");
sb.append(" message: ").append(toIndentedString(message)).append("\n");
sb.append(" messageWithParams: ").append(toIndentedString(messageWithParams)).append("\n");
sb.append(" messageParams: ").append(toIndentedString(messageParams)).append("\n");
sb.append(" code: ").append(toIndentedString(code)).append("\n");
sb.append(" contextId: ").append(toIndentedString(contextId)).append("\n");
sb.append(" nested: ").append(toIndentedString(nested)).append("\n");
sb.append(" details: ").append(toIndentedString(details)).append("\n");
sb.append("}");
return sb.toString();
}
/**
* Convert the given object to string with each line indented by 4 spaces
* (except the first line).
*/
private String toIndentedString(java.lang.Object o) {
if (o == null) {
return "null";
}
return o.toString().replace("\n", "\n ");
}
}