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 java.util.ArrayList;
import java.util.List;
import java.util.Objects;

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

public class CreateMdnsRuleOpenApiVo   {
  @JsonProperty("name")
  private String name;

  @JsonProperty("status")
  private Boolean status;

  @JsonProperty("profileIds")
  @Valid
  private List<String> profileIds = new ArrayList<>();

  @JsonProperty("type")
  private Integer type;

  @JsonProperty("ap")
  private ApMdnsRuleOpenApiVo ap;

  @JsonProperty("osg")
  private OsgMdnsRuleOpenApiVo osg;

  public CreateMdnsRuleOpenApiVo name(String name) {
    this.name = name;
    return this;
  }

  /**
   * MDNS rule name. Name should contain 1 to 64 characters
   * @return name
  */
  @ApiModelProperty(required = true, value = "MDNS rule name. Name should contain 1 to 64 characters")
  @NotNull


  public String getName() {
    return name;
  }

  public void setName(String name) {
    this.name = name;
  }

  public CreateMdnsRuleOpenApiVo status(Boolean status) {
    this.status = status;
    return this;
  }

  /**
   * MDNS rule enable status
   * @return status
  */
  @ApiModelProperty(required = true, value = "MDNS rule enable status")
  @NotNull


  public Boolean getStatus() {
    return status;
  }

  public void setStatus(Boolean status) {
    this.status = status;
  }

  public CreateMdnsRuleOpenApiVo profileIds(List<String> profileIds) {
    this.profileIds = profileIds;
    return this;
  }

  public CreateMdnsRuleOpenApiVo addProfileIdsItem(String profileIdsItem) {
    this.profileIds.add(profileIdsItem);
    return this;
  }

  /**
   * This field represents Bonjour service profile ID. Bonjour Service Profile can be created using 'Create new Bonjour Service' interface, and Bonjour service profile ID can be obtained from 'Get Bonjour Service list' interface
   * @return profileIds
  */
  @ApiModelProperty(required = true, value = "This field represents Bonjour service profile ID. Bonjour Service Profile can be created using 'Create new Bonjour Service' interface, and Bonjour service profile ID can be obtained from 'Get Bonjour Service list' interface")
  @NotNull


  public List<String> getProfileIds() {
    return profileIds;
  }

  public void setProfileIds(List<String> profileIds) {
    this.profileIds = profileIds;
  }

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

  /**
   * MDNS rule type. Type should be a value as follows: 0: AP, 1: Gateway
   * @return type
  */
  @ApiModelProperty(value = "MDNS rule type. Type should be a value as follows: 0: AP, 1: Gateway")


  public Integer getType() {
    return type;
  }

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

  public CreateMdnsRuleOpenApiVo ap(ApMdnsRuleOpenApiVo ap) {
    this.ap = ap;
    return this;
  }

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

  @Valid

  public ApMdnsRuleOpenApiVo getAp() {
    return ap;
  }

  public void setAp(ApMdnsRuleOpenApiVo ap) {
    this.ap = ap;
  }

  public CreateMdnsRuleOpenApiVo osg(OsgMdnsRuleOpenApiVo osg) {
    this.osg = osg;
    return this;
  }

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

  @Valid

  public OsgMdnsRuleOpenApiVo getOsg() {
    return osg;
  }

  public void setOsg(OsgMdnsRuleOpenApiVo osg) {
    this.osg = osg;
  }


  @Override
  public boolean equals(Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    CreateMdnsRuleOpenApiVo createMdnsRuleOpenApiVo = (CreateMdnsRuleOpenApiVo) o;
    return Objects.equals(this.name, createMdnsRuleOpenApiVo.name) &&
        Objects.equals(this.status, createMdnsRuleOpenApiVo.status) &&
        Objects.equals(this.profileIds, createMdnsRuleOpenApiVo.profileIds) &&
        Objects.equals(this.type, createMdnsRuleOpenApiVo.type) &&
        Objects.equals(this.ap, createMdnsRuleOpenApiVo.ap) &&
        Objects.equals(this.osg, createMdnsRuleOpenApiVo.osg);
  }

  @Override
  public int hashCode() {
    return Objects.hash(name, status, profileIds, type, ap, osg);
  }

  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class CreateMdnsRuleOpenApiVo {\n");
    
    sb.append("    name: ").append(toIndentedString(name)).append("\n");
    sb.append("    status: ").append(toIndentedString(status)).append("\n");
    sb.append("    profileIds: ").append(toIndentedString(profileIds)).append("\n");
    sb.append("    type: ").append(toIndentedString(type)).append("\n");
    sb.append("    ap: ").append(toIndentedString(ap)).append("\n");
    sb.append("    osg: ").append(toIndentedString(osg)).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    ");
  }
}

