cloud.genesys.webmessaging.sdk.model.ContentLocation Maven / Gradle / Ivy
package cloud.genesys.webmessaging.sdk.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.io.IOException;
import com.fasterxml.jackson.annotation.JsonProperty;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import java.io.Serializable;
/**
* Location content. Location object.
*/
@ApiModel(description = "Location content. Location object.")
public class ContentLocation implements Serializable {
private String address = null;
private Double latitude = null;
private Double longitude = null;
private String text = null;
private String url = null;
/**
* Location postal address.
**/
public ContentLocation address(String address) {
this.address = address;
return this;
}
@ApiModelProperty(example = "null", value = "Location postal address.")
@JsonProperty("address")
public String getAddress() {
return address;
}
public void setAddress(String address) {
this.address = address;
}
/**
* Latitude of the location.
**/
public ContentLocation latitude(Double latitude) {
this.latitude = latitude;
return this;
}
@ApiModelProperty(example = "null", value = "Latitude of the location.")
@JsonProperty("latitude")
public Double getLatitude() {
return latitude;
}
public void setLatitude(Double latitude) {
this.latitude = latitude;
}
/**
* Longitude of the location.
**/
public ContentLocation longitude(Double longitude) {
this.longitude = longitude;
return this;
}
@ApiModelProperty(example = "null", value = "Longitude of the location.")
@JsonProperty("longitude")
public Double getLongitude() {
return longitude;
}
public void setLongitude(Double longitude) {
this.longitude = longitude;
}
/**
* Location name.
**/
public ContentLocation text(String text) {
this.text = text;
return this;
}
@ApiModelProperty(example = "null", value = "Location name.")
@JsonProperty("text")
public String getText() {
return text;
}
public void setText(String text) {
this.text = text;
}
/**
* URL of the Location.
**/
public ContentLocation url(String url) {
this.url = url;
return this;
}
@ApiModelProperty(example = "null", value = "URL of the Location.")
@JsonProperty("url")
public String getUrl() {
return url;
}
public void setUrl(String url) {
this.url = url;
}
@Override
public boolean equals(java.lang.Object o) {
if (this == o) {
return true;
}
if (o == null || getClass() != o.getClass()) {
return false;
}
ContentLocation contentLocation = (ContentLocation) o;
return Objects.equals(this.address, contentLocation.address) &&
Objects.equals(this.latitude, contentLocation.latitude) &&
Objects.equals(this.longitude, contentLocation.longitude) &&
Objects.equals(this.text, contentLocation.text) &&
Objects.equals(this.url, contentLocation.url);
}
@Override
public int hashCode() {
return Objects.hash(address, latitude, longitude, text, url);
}
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class ContentLocation {\n");
sb.append(" address: ").append(toIndentedString(address)).append("\n");
sb.append(" latitude: ").append(toIndentedString(latitude)).append("\n");
sb.append(" longitude: ").append(toIndentedString(longitude)).append("\n");
sb.append(" text: ").append(toIndentedString(text)).append("\n");
sb.append(" url: ").append(toIndentedString(url)).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 ");
}
}