package org.wfc.omada.api.msp.model;

import com.fasterxml.jackson.annotation.JsonProperty;
import io.swagger.annotations.ApiModelProperty;

import javax.validation.constraints.Pattern;
import java.util.Objects;

/**
 * CustomerOpenApiVo
 */
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.SpringCodegen", date = "2024-12-04T11:44:08.065+08:00[Asia/Shanghai]")

public class CustomerOpenApiVo   {
  @JsonProperty("customerName")
  private String customerName;

  @JsonProperty("description")
  private String description;

  public CustomerOpenApiVo customerName(String customerName) {
    this.customerName = customerName;
    return this;
  }

  /**
   * Customer name should contain 1 to 31 characters.
   * @return customerName
  */
  @ApiModelProperty(value = "Customer name should contain 1 to 31 characters.")

@Pattern(regexp="^[^ \\+\\-\\@\\=]$|^[^ \\+\\-\\@\\=].{0,30}[^ ]$") 
  public String getCustomerName() {
    return customerName;
  }

  public void setCustomerName(String customerName) {
    this.customerName = customerName;
  }

  public CustomerOpenApiVo description(String description) {
    this.description = description;
    return this;
  }

  /**
   * Customer description should contain 1 to 128 characters.
   * @return description
  */
  @ApiModelProperty(value = "Customer description should contain 1 to 128 characters.")

@Pattern(regexp="^$|^[^ ]$|^[^ ].*\\r?\\n?.*{0,126}[^ ]$") 
  public String getDescription() {
    return description;
  }

  public void setDescription(String description) {
    this.description = description;
  }


  @Override
  public boolean equals(Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    CustomerOpenApiVo customerOpenApiVo = (CustomerOpenApiVo) o;
    return Objects.equals(this.customerName, customerOpenApiVo.customerName) &&
        Objects.equals(this.description, customerOpenApiVo.description);
  }

  @Override
  public int hashCode() {
    return Objects.hash(customerName, description);
  }

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

