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

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

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

  @JsonProperty("siteId")
  private String siteId;

  @JsonProperty("name")
  private String name;

  @JsonProperty("status")
  private Boolean status;

  @JsonProperty("turnOnTime")
  private String turnOnTime;

  @JsonProperty("poePortsMap")
  @Valid
  private Map<String, List<Integer>> poePortsMap = new HashMap<>();

  @JsonProperty("nextExecute")
  private Long nextExecute;

  @JsonProperty("notInDst")
  private Boolean notInDst;

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

  /**
   * PoE Schedule Individual ID.
   * @return id
  */
  @ApiModelProperty(value = "PoE Schedule Individual ID.")


  public String getId() {
    return id;
  }

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

  public PoeScheduleQueryOpenApiVo siteId(String siteId) {
    this.siteId = siteId;
    return this;
  }

  /**
   * Site ID
   * @return siteId
  */
  @ApiModelProperty(value = "Site ID")


  public String getSiteId() {
    return siteId;
  }

  public void setSiteId(String siteId) {
    this.siteId = siteId;
  }

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

  /**
   * PoE Schedule Name should contain 1 to 128 characters.
   * @return name
  */
  @ApiModelProperty(required = true, value = "PoE Schedule Name should contain 1 to 128 characters.")
  @NotNull

@Pattern(regexp="^[^ ]$|^[^ ].{0,126}[^ ]$") 
  public String getName() {
    return name;
  }

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

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

  /**
   * PoE Schedule Status.
   * @return status
  */
  @ApiModelProperty(required = true, value = "PoE Schedule Status.")
  @NotNull


  public Boolean getStatus() {
    return status;
  }

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

  public PoeScheduleQueryOpenApiVo turnOnTime(String turnOnTime) {
    this.turnOnTime = turnOnTime;
    return this;
  }

  /**
   * Time Range ID, cannot be empty.
   * @return turnOnTime
  */
  @ApiModelProperty(required = true, value = "Time Range ID, cannot be empty.")
  @NotNull


  public String getTurnOnTime() {
    return turnOnTime;
  }

  public void setTurnOnTime(String turnOnTime) {
    this.turnOnTime = turnOnTime;
  }

  public PoeScheduleQueryOpenApiVo poePortsMap(Map<String, List<Integer>> poePortsMap) {
    this.poePortsMap = poePortsMap;
    return this;
  }

  public PoeScheduleQueryOpenApiVo putPoePortsMapItem(String key, List<Integer> poePortsMapItem) {
    this.poePortsMap.put(key, poePortsMapItem);
    return this;
  }

  /**
   * Key:Mac(\"String\"), Value:Set of Ports(\"Integer\")
   * @return poePortsMap
  */
  @ApiModelProperty(required = true, value = "Key:Mac(\"String\"), Value:Set of Ports(\"Integer\")")
  @NotNull

  @Valid

  public Map<String, List<Integer>> getPoePortsMap() {
    return poePortsMap;
  }

  public void setPoePortsMap(Map<String, List<Integer>> poePortsMap) {
    this.poePortsMap = poePortsMap;
  }

  public PoeScheduleQueryOpenApiVo nextExecute(Long nextExecute) {
    this.nextExecute = nextExecute;
    return this;
  }

  /**
   * Show PoE Schedule next execution timestamp.
   * @return nextExecute
  */
  @ApiModelProperty(value = "Show PoE Schedule next execution timestamp.")


  public Long getNextExecute() {
    return nextExecute;
  }

  public void setNextExecute(Long nextExecute) {
    this.nextExecute = nextExecute;
  }

  public PoeScheduleQueryOpenApiVo notInDst(Boolean notInDst) {
    this.notInDst = notInDst;
    return this;
  }

  /**
   * When notInDst is true, not displayed in DST.
   * @return notInDst
  */
  @ApiModelProperty(value = "When notInDst is true, not displayed in DST.")


  public Boolean getNotInDst() {
    return notInDst;
  }

  public void setNotInDst(Boolean notInDst) {
    this.notInDst = notInDst;
  }


  @Override
  public boolean equals(Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    PoeScheduleQueryOpenApiVo poeScheduleQueryOpenApiVo = (PoeScheduleQueryOpenApiVo) o;
    return Objects.equals(this.id, poeScheduleQueryOpenApiVo.id) &&
        Objects.equals(this.siteId, poeScheduleQueryOpenApiVo.siteId) &&
        Objects.equals(this.name, poeScheduleQueryOpenApiVo.name) &&
        Objects.equals(this.status, poeScheduleQueryOpenApiVo.status) &&
        Objects.equals(this.turnOnTime, poeScheduleQueryOpenApiVo.turnOnTime) &&
        Objects.equals(this.poePortsMap, poeScheduleQueryOpenApiVo.poePortsMap) &&
        Objects.equals(this.nextExecute, poeScheduleQueryOpenApiVo.nextExecute) &&
        Objects.equals(this.notInDst, poeScheduleQueryOpenApiVo.notInDst);
  }

  @Override
  public int hashCode() {
    return Objects.hash(id, siteId, name, status, turnOnTime, poePortsMap, nextExecute, notInDst);
  }

  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class PoeScheduleQueryOpenApiVo {\n");
    
    sb.append("    id: ").append(toIndentedString(id)).append("\n");
    sb.append("    siteId: ").append(toIndentedString(siteId)).append("\n");
    sb.append("    name: ").append(toIndentedString(name)).append("\n");
    sb.append("    status: ").append(toIndentedString(status)).append("\n");
    sb.append("    turnOnTime: ").append(toIndentedString(turnOnTime)).append("\n");
    sb.append("    poePortsMap: ").append(toIndentedString(poePortsMap)).append("\n");
    sb.append("    nextExecute: ").append(toIndentedString(nextExecute)).append("\n");
    sb.append("    notInDst: ").append(toIndentedString(notInDst)).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    ");
  }
}

