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

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

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

/**
 * MDNS rule AP config, valid when parameter [type] is 0
 */
@ApiModel(description = "MDNS rule AP config, valid when parameter [type] is 0")
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.SpringCodegen", date = "2024-12-04T11:32:19.054+08:00[Asia/Shanghai]")

public class ApMdnsRuleOpenApiVo   {
  @JsonProperty("serviceVlan")
  private String serviceVlan;

  @JsonProperty("clientVlan")
  private String clientVlan;

  public ApMdnsRuleOpenApiVo serviceVlan(String serviceVlan) {
    this.serviceVlan = serviceVlan;
    return this;
  }

  /**
   * Services Network VLAN. ServiceVlan should be within the range of 1 to 4094. Enter only one VLAN
   * @return serviceVlan
  */
  @ApiModelProperty(required = true, value = "Services Network VLAN. ServiceVlan should be within the range of 1 to 4094. Enter only one VLAN")
  @NotNull


  public String getServiceVlan() {
    return serviceVlan;
  }

  public void setServiceVlan(String serviceVlan) {
    this.serviceVlan = serviceVlan;
  }

  public ApMdnsRuleOpenApiVo clientVlan(String clientVlan) {
    this.clientVlan = clientVlan;
    return this;
  }

  /**
   * Client Network VLAN. ClientVlan should be within the range of 1 to 4094. Enter one or multiple VLANs. For example: 1,2-100
   * @return clientVlan
  */
  @ApiModelProperty(required = true, value = "Client Network VLAN. ClientVlan should be within the range of 1 to 4094. Enter one or multiple VLANs. For example: 1,2-100")
  @NotNull

@Pattern(regexp="^[\\d|\\d-\\d]+(,[\\d|\\d-\\d]+)*$") 
  public String getClientVlan() {
    return clientVlan;
  }

  public void setClientVlan(String clientVlan) {
    this.clientVlan = clientVlan;
  }


  @Override
  public boolean equals(Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    ApMdnsRuleOpenApiVo apMdnsRuleOpenApiVo = (ApMdnsRuleOpenApiVo) o;
    return Objects.equals(this.serviceVlan, apMdnsRuleOpenApiVo.serviceVlan) &&
        Objects.equals(this.clientVlan, apMdnsRuleOpenApiVo.clientVlan);
  }

  @Override
  public int hashCode() {
    return Objects.hash(serviceVlan, clientVlan);
  }

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

