com.algolia.model.recommend.Range Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of algoliasearch Show documentation
Show all versions of algoliasearch Show documentation
Java client for Algolia Search API
The newest version!
// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost
// - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
package com.algolia.model.recommend;
import com.fasterxml.jackson.annotation.*;
import com.fasterxml.jackson.databind.annotation.*;
import java.util.Objects;
/** Range object with lower and upper values in meters to define custom ranges. */
public class Range {
@JsonProperty("from")
private Integer from;
@JsonProperty("value")
private Integer value;
public Range setFrom(Integer from) {
this.from = from;
return this;
}
/**
* Lower boundary of a range in meters. The Geo ranking criterion considers all records within the
* range to be equal.
*/
@javax.annotation.Nullable
public Integer getFrom() {
return from;
}
public Range setValue(Integer value) {
this.value = value;
return this;
}
/**
* Upper boundary of a range in meters. The Geo ranking criterion considers all records within the
* range to be equal.
*/
@javax.annotation.Nullable
public Integer getValue() {
return value;
}
@Override
public boolean equals(Object o) {
if (this == o) {
return true;
}
if (o == null || getClass() != o.getClass()) {
return false;
}
Range range = (Range) o;
return Objects.equals(this.from, range.from) && Objects.equals(this.value, range.value);
}
@Override
public int hashCode() {
return Objects.hash(from, value);
}
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class Range {\n");
sb.append(" from: ").append(toIndentedString(from)).append("\n");
sb.append(" value: ").append(toIndentedString(value)).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(Object o) {
if (o == null) {
return "null";
}
return o.toString().replace("\n", "\n ");
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy