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

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

import javax.validation.Valid;
import javax.validation.constraints.NotNull;
import java.util.ArrayList;
import java.util.List;
import java.util.Objects;

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

public class LicenseAssignmentOpenApiVo   {
  @JsonProperty("customerId")
  private String customerId;

  @JsonProperty("licenseNum")
  @Valid
  private List<LicenseNumOpenApiVo> licenseNum = new ArrayList<>();

  @JsonProperty("others")
  private LicenseOthersIdsOpenApiVo others;

  public LicenseAssignmentOpenApiVo customerId(String customerId) {
    this.customerId = customerId;
    return this;
  }

  /**
   * Customer ID
   * @return customerId
  */
  @ApiModelProperty(required = true, value = "Customer ID")
  @NotNull


  public String getCustomerId() {
    return customerId;
  }

  public void setCustomerId(String customerId) {
    this.customerId = customerId;
  }

  public LicenseAssignmentOpenApiVo licenseNum(List<LicenseNumOpenApiVo> licenseNum) {
    this.licenseNum = licenseNum;
    return this;
  }

  public LicenseAssignmentOpenApiVo addLicenseNumItem(LicenseNumOpenApiVo licenseNumItem) {
    this.licenseNum.add(licenseNumItem);
    return this;
  }

  /**
   * License num
   * @return licenseNum
  */
  @ApiModelProperty(required = true, value = "License num")
  @NotNull

  @Valid

  public List<LicenseNumOpenApiVo> getLicenseNum() {
    return licenseNum;
  }

  public void setLicenseNum(List<LicenseNumOpenApiVo> licenseNum) {
    this.licenseNum = licenseNum;
  }

  public LicenseAssignmentOpenApiVo others(LicenseOthersIdsOpenApiVo others) {
    this.others = others;
    return this;
  }

  /**
   * Get others
   * @return others
  */
  @ApiModelProperty(required = true, value = "")
  @NotNull

  @Valid

  public LicenseOthersIdsOpenApiVo getOthers() {
    return others;
  }

  public void setOthers(LicenseOthersIdsOpenApiVo others) {
    this.others = others;
  }


  @Override
  public boolean equals(Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    LicenseAssignmentOpenApiVo licenseAssignmentOpenApiVo = (LicenseAssignmentOpenApiVo) o;
    return Objects.equals(this.customerId, licenseAssignmentOpenApiVo.customerId) &&
        Objects.equals(this.licenseNum, licenseAssignmentOpenApiVo.licenseNum) &&
        Objects.equals(this.others, licenseAssignmentOpenApiVo.others);
  }

  @Override
  public int hashCode() {
    return Objects.hash(customerId, licenseNum, others);
  }

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

