org.opendatadiscovery.client.model.HistogramValue Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of ingestion-contract-client Show documentation
Show all versions of ingestion-contract-client Show documentation
Ingestion Contract WebFlux Client defines OpenDataDiscovery APIs and models for Spring WebClient
/*
* OpenDataDiscovery API Contract
* OpenDataDiscovery API Contract
*
* The version of the OpenAPI document: 0.0.1
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
package org.opendatadiscovery.client.model;
import java.util.Objects;
import java.util.Arrays;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonTypeName;
import com.fasterxml.jackson.annotation.JsonValue;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import java.math.BigDecimal;
import java.util.ArrayList;
import java.util.List;
import org.opendatadiscovery.client.model.Bucket;
import com.fasterxml.jackson.annotation.JsonPropertyOrder;
/**
* HistogramValue
*/
@JsonPropertyOrder({
HistogramValue.JSON_PROPERTY_SUM,
HistogramValue.JSON_PROPERTY_COUNT,
HistogramValue.JSON_PROPERTY_CREATED,
HistogramValue.JSON_PROPERTY_BUCKETS
})
@JsonTypeName("HistogramValue")
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2023-07-18T08:56:03.217273Z[Etc/UTC]")
public class HistogramValue {
public static final String JSON_PROPERTY_SUM = "sum";
private BigDecimal sum;
public static final String JSON_PROPERTY_COUNT = "count";
private Long count;
public static final String JSON_PROPERTY_CREATED = "created";
private Integer created;
public static final String JSON_PROPERTY_BUCKETS = "buckets";
private List buckets = null;
public HistogramValue sum(BigDecimal sum) {
this.sum = sum;
return this;
}
/**
* Get sum
* @return sum
**/
@javax.annotation.Nullable
@ApiModelProperty(value = "")
@JsonProperty(JSON_PROPERTY_SUM)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public BigDecimal getSum() {
return sum;
}
@JsonProperty(JSON_PROPERTY_SUM)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public void setSum(BigDecimal sum) {
this.sum = sum;
}
public HistogramValue count(Long count) {
this.count = count;
return this;
}
/**
* Get count
* @return count
**/
@javax.annotation.Nullable
@ApiModelProperty(value = "")
@JsonProperty(JSON_PROPERTY_COUNT)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public Long getCount() {
return count;
}
@JsonProperty(JSON_PROPERTY_COUNT)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public void setCount(Long count) {
this.count = count;
}
public HistogramValue created(Integer created) {
this.created = created;
return this;
}
/**
* Get created
* @return created
**/
@javax.annotation.Nullable
@ApiModelProperty(value = "")
@JsonProperty(JSON_PROPERTY_CREATED)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public Integer getCreated() {
return created;
}
@JsonProperty(JSON_PROPERTY_CREATED)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public void setCreated(Integer created) {
this.created = created;
}
public HistogramValue buckets(List buckets) {
this.buckets = buckets;
return this;
}
public HistogramValue addBucketsItem(Bucket bucketsItem) {
if (this.buckets == null) {
this.buckets = new ArrayList<>();
}
this.buckets.add(bucketsItem);
return this;
}
/**
* Get buckets
* @return buckets
**/
@javax.annotation.Nullable
@ApiModelProperty(value = "")
@JsonProperty(JSON_PROPERTY_BUCKETS)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public List getBuckets() {
return buckets;
}
@JsonProperty(JSON_PROPERTY_BUCKETS)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public void setBuckets(List buckets) {
this.buckets = buckets;
}
@Override
public boolean equals(Object o) {
if (this == o) {
return true;
}
if (o == null || getClass() != o.getClass()) {
return false;
}
HistogramValue histogramValue = (HistogramValue) o;
return Objects.equals(this.sum, histogramValue.sum) &&
Objects.equals(this.count, histogramValue.count) &&
Objects.equals(this.created, histogramValue.created) &&
Objects.equals(this.buckets, histogramValue.buckets);
}
@Override
public int hashCode() {
return Objects.hash(sum, count, created, buckets);
}
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class HistogramValue {\n");
sb.append(" sum: ").append(toIndentedString(sum)).append("\n");
sb.append(" count: ").append(toIndentedString(count)).append("\n");
sb.append(" created: ").append(toIndentedString(created)).append("\n");
sb.append(" buckets: ").append(toIndentedString(buckets)).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 - 2024 Weber Informatics LLC | Privacy Policy