dev.crashteam.openapi.analytics.model.DailyCategoryAnalytics Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of openapi-analytics Show documentation
Show all versions of openapi-analytics Show documentation
Generates jar artifact containing compiled openapi classes based on generated openapi yaml files
The newest version!
package dev.crashteam.openapi.analytics.model;
import java.net.URI;
import java.util.Objects;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonCreator;
import java.time.LocalDate;
import org.springframework.format.annotation.DateTimeFormat;
import org.openapitools.jackson.nullable.JsonNullable;
import java.time.OffsetDateTime;
import javax.validation.Valid;
import javax.validation.constraints.*;
import io.swagger.v3.oas.annotations.media.Schema;
import java.util.*;
import javax.annotation.Generated;
/**
* DailyCategoryAnalytics
*/
@Generated(value = "org.openapitools.codegen.languages.SpringCodegen", date = "2024-04-04T20:14:40.494067127Z[Etc/UTC]", comments = "Generator version: 7.4.0")
public class DailyCategoryAnalytics {
@DateTimeFormat(iso = DateTimeFormat.ISO.DATE)
private LocalDate date;
private Double revenue;
private Double averageBill;
private Long sales;
private Long remainings;
public DailyCategoryAnalytics date(LocalDate date) {
this.date = date;
return this;
}
/**
* Date
* @return date
*/
@Valid @Pattern(regexp = "YYYY-MM-DD")
@Schema(name = "date", example = "Sun Jan 01 00:00:00 UTC 2017", description = "Date", requiredMode = Schema.RequiredMode.NOT_REQUIRED)
@JsonProperty("date")
public LocalDate getDate() {
return date;
}
public void setDate(LocalDate date) {
this.date = date;
}
public DailyCategoryAnalytics revenue(Double revenue) {
this.revenue = revenue;
return this;
}
/**
* Выручка в валюте
* @return revenue
*/
@Schema(name = "revenue", description = "Выручка в валюте", requiredMode = Schema.RequiredMode.NOT_REQUIRED)
@JsonProperty("revenue")
public Double getRevenue() {
return revenue;
}
public void setRevenue(Double revenue) {
this.revenue = revenue;
}
public DailyCategoryAnalytics averageBill(Double averageBill) {
this.averageBill = averageBill;
return this;
}
/**
* Средний чек в валюте
* @return averageBill
*/
@Schema(name = "average_bill", description = "Средний чек в валюте", requiredMode = Schema.RequiredMode.NOT_REQUIRED)
@JsonProperty("average_bill")
public Double getAverageBill() {
return averageBill;
}
public void setAverageBill(Double averageBill) {
this.averageBill = averageBill;
}
public DailyCategoryAnalytics sales(Long sales) {
this.sales = sales;
return this;
}
/**
* Продажи, шт
* @return sales
*/
@Schema(name = "sales", description = "Продажи, шт", requiredMode = Schema.RequiredMode.NOT_REQUIRED)
@JsonProperty("sales")
public Long getSales() {
return sales;
}
public void setSales(Long sales) {
this.sales = sales;
}
public DailyCategoryAnalytics remainings(Long remainings) {
this.remainings = remainings;
return this;
}
/**
* Остатки на складе, шт
* @return remainings
*/
@Schema(name = "remainings", description = "Остатки на складе, шт", requiredMode = Schema.RequiredMode.NOT_REQUIRED)
@JsonProperty("remainings")
public Long getRemainings() {
return remainings;
}
public void setRemainings(Long remainings) {
this.remainings = remainings;
}
@Override
public boolean equals(Object o) {
if (this == o) {
return true;
}
if (o == null || getClass() != o.getClass()) {
return false;
}
DailyCategoryAnalytics dailyCategoryAnalytics = (DailyCategoryAnalytics) o;
return Objects.equals(this.date, dailyCategoryAnalytics.date) &&
Objects.equals(this.revenue, dailyCategoryAnalytics.revenue) &&
Objects.equals(this.averageBill, dailyCategoryAnalytics.averageBill) &&
Objects.equals(this.sales, dailyCategoryAnalytics.sales) &&
Objects.equals(this.remainings, dailyCategoryAnalytics.remainings);
}
@Override
public int hashCode() {
return Objects.hash(date, revenue, averageBill, sales, remainings);
}
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class DailyCategoryAnalytics {\n");
sb.append(" date: ").append(toIndentedString(date)).append("\n");
sb.append(" revenue: ").append(toIndentedString(revenue)).append("\n");
sb.append(" averageBill: ").append(toIndentedString(averageBill)).append("\n");
sb.append(" sales: ").append(toIndentedString(sales)).append("\n");
sb.append(" remainings: ").append(toIndentedString(remainings)).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 ");
}
}