All Downloads are FREE. Search and download functionalities are using the official Maven repository.

dev.crashteam.openapi.keanalytics.model.DiscountPromoCodeAllOf Maven / Gradle / Ivy

Go to download

Generates jar artifact containing compiled openapi classes based on generated openapi yaml files

The newest version!
package dev.crashteam.openapi.keanalytics.model;

import java.net.URI;
import java.util.Objects;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonTypeName;
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;

/**
 * DiscountPromoCodeAllOf
 */

@JsonTypeName("DiscountPromoCode_allOf")
@Generated(value = "org.openapitools.codegen.languages.SpringCodegen", date = "2024-03-26T08:59:12.399131532Z[Etc/UTC]")
public class DiscountPromoCodeAllOf {

  private Integer discount;

  /**
   * Default constructor
   * @deprecated Use {@link DiscountPromoCodeAllOf#DiscountPromoCodeAllOf(Integer)}
   */
  @Deprecated
  public DiscountPromoCodeAllOf() {
    super();
  }

  /**
   * Constructor with only required parameters
   */
  public DiscountPromoCodeAllOf(Integer discount) {
    this.discount = discount;
  }

  public DiscountPromoCodeAllOf discount(Integer discount) {
    this.discount = discount;
    return this;
  }

  /**
   * Скидка при покупке
   * minimum: 1
   * maximum: 99
   * @return discount
  */
  @NotNull @Min(1) @Max(99) 
  @Schema(name = "discount", description = "Скидка при покупке", requiredMode = Schema.RequiredMode.REQUIRED)
  @JsonProperty("discount")
  public Integer getDiscount() {
    return discount;
  }

  public void setDiscount(Integer discount) {
    this.discount = discount;
  }

  @Override
  public boolean equals(Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    DiscountPromoCodeAllOf discountPromoCodeAllOf = (DiscountPromoCodeAllOf) o;
    return Objects.equals(this.discount, discountPromoCodeAllOf.discount);
  }

  @Override
  public int hashCode() {
    return Objects.hash(discount);
  }

  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class DiscountPromoCodeAllOf {\n");
    sb.append("    discount: ").append(toIndentedString(discount)).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