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

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

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

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

public class PpskProfileVo   {
  @JsonProperty("id")
  private String id;

  @JsonProperty("profileName")
  private String profileName;

  @JsonProperty("ssid")
  @Valid
  private List<String> ssid = null;

  @JsonProperty("ppsk")
  @Valid
  private List<Pskvo> ppsk = new ArrayList<>();

  @JsonProperty("type")
  private Integer type;

  @JsonProperty("resource")
  private Integer resource;

  public PpskProfileVo id(String id) {
    this.id = id;
    return this;
  }

  /**
   * PPSK Profile ID
   * @return id
  */
  @ApiModelProperty(value = "PPSK Profile ID")


  public String getId() {
    return id;
  }

  public void setId(String id) {
    this.id = id;
  }

  public PpskProfileVo profileName(String profileName) {
    this.profileName = profileName;
    return this;
  }

  /**
   * PPSK Profile Name
   * @return profileName
  */
  @ApiModelProperty(required = true, value = "PPSK Profile Name")
  @NotNull

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

  public void setProfileName(String profileName) {
    this.profileName = profileName;
  }

  public PpskProfileVo ssid(List<String> ssid) {
    this.ssid = ssid;
    return this;
  }

  public PpskProfileVo addSsidItem(String ssidItem) {
    if (this.ssid == null) {
      this.ssid = new ArrayList<>();
    }
    this.ssid.add(ssidItem);
    return this;
  }

  /**
   * Ssid List Bound With PPSK Profile
   * @return ssid
  */
  @ApiModelProperty(value = "Ssid List Bound With PPSK Profile")


  public List<String> getSsid() {
    return ssid;
  }

  public void setSsid(List<String> ssid) {
    this.ssid = ssid;
  }

  public PpskProfileVo ppsk(List<Pskvo> ppsk) {
    this.ppsk = ppsk;
    return this;
  }

  public PpskProfileVo addPpskItem(Pskvo ppskItem) {
    this.ppsk.add(ppskItem);
    return this;
  }

  /**
   * PSK List In the PPSK Profile
   * @return ppsk
  */
  @ApiModelProperty(required = true, value = "PSK List In the PPSK Profile")
  @NotNull

  @Valid

  public List<Pskvo> getPpsk() {
    return ppsk;
  }

  public void setPpsk(List<Pskvo> ppsk) {
    this.ppsk = ppsk;
  }

  public PpskProfileVo type(Integer type) {
    this.type = type;
    return this;
  }

  /**
   * PPSK Profile type: 0：PPSK Without RADIUS; 1: PPSK With Built-In RADIUS.
   * @return type
  */
  @ApiModelProperty(value = "PPSK Profile type: 0：PPSK Without RADIUS; 1: PPSK With Built-In RADIUS.")


  public Integer getType() {
    return type;
  }

  public void setType(Integer type) {
    this.type = type;
  }

  public PpskProfileVo resource(Integer resource) {
    this.resource = resource;
    return this;
  }

  /**
   * Get resource
   * @return resource
  */
  @ApiModelProperty(value = "")


  public Integer getResource() {
    return resource;
  }

  public void setResource(Integer resource) {
    this.resource = resource;
  }


  @Override
  public boolean equals(Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    PpskProfileVo ppskProfileVo = (PpskProfileVo) o;
    return Objects.equals(this.id, ppskProfileVo.id) &&
        Objects.equals(this.profileName, ppskProfileVo.profileName) &&
        Objects.equals(this.ssid, ppskProfileVo.ssid) &&
        Objects.equals(this.ppsk, ppskProfileVo.ppsk) &&
        Objects.equals(this.type, ppskProfileVo.type) &&
        Objects.equals(this.resource, ppskProfileVo.resource);
  }

  @Override
  public int hashCode() {
    return Objects.hash(id, profileName, ssid, ppsk, type, resource);
  }

  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class PpskProfileVo {\n");
    
    sb.append("    id: ").append(toIndentedString(id)).append("\n");
    sb.append("    profileName: ").append(toIndentedString(profileName)).append("\n");
    sb.append("    ssid: ").append(toIndentedString(ssid)).append("\n");
    sb.append("    ppsk: ").append(toIndentedString(ppsk)).append("\n");
    sb.append("    type: ").append(toIndentedString(type)).append("\n");
    sb.append("    resource: ").append(toIndentedString(resource)).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    ");
  }
}

