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

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

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

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

public class CallForwardingRulesGrid   {
  @JsonProperty("totalRows")
  private Long totalRows;

  @JsonProperty("currentPage")
  private Integer currentPage;

  @JsonProperty("currentSize")
  private Integer currentSize;

  @JsonProperty("data")
  @Valid
  private List<Object> data = null;

  @JsonProperty("numberList")
  @Valid
  private List<NumberOpenApiVo> numberList = null;

  @JsonProperty("deviceList")
  @Valid
  private List<DeviceOpenApiVo> deviceList = null;

  @JsonProperty("bookList")
  @Valid
  private List<BookOpenApiVo> bookList = null;

  public CallForwardingRulesGrid totalRows(Long totalRows) {
    this.totalRows = totalRows;
    return this;
  }

  /**
   * Total rows of all items.
   * @return totalRows
  */
  @ApiModelProperty(value = "Total rows of all items.")


  public Long getTotalRows() {
    return totalRows;
  }

  public void setTotalRows(Long totalRows) {
    this.totalRows = totalRows;
  }

  public CallForwardingRulesGrid currentPage(Integer currentPage) {
    this.currentPage = currentPage;
    return this;
  }

  /**
   * Current page number.
   * @return currentPage
  */
  @ApiModelProperty(value = "Current page number.")


  public Integer getCurrentPage() {
    return currentPage;
  }

  public void setCurrentPage(Integer currentPage) {
    this.currentPage = currentPage;
  }

  public CallForwardingRulesGrid currentSize(Integer currentSize) {
    this.currentSize = currentSize;
    return this;
  }

  /**
   * Number of entries per page.
   * @return currentSize
  */
  @ApiModelProperty(value = "Number of entries per page.")


  public Integer getCurrentSize() {
    return currentSize;
  }

  public void setCurrentSize(Integer currentSize) {
    this.currentSize = currentSize;
  }

  public CallForwardingRulesGrid data(List<Object> data) {
    this.data = data;
    return this;
  }

  public CallForwardingRulesGrid addDataItem(Object dataItem) {
    if (this.data == null) {
      this.data = new ArrayList<>();
    }
    this.data.add(dataItem);
    return this;
  }

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


  public List<Object> getData() {
    return data;
  }

  public void setData(List<Object> data) {
    this.data = data;
  }

  public CallForwardingRulesGrid numberList(List<NumberOpenApiVo> numberList) {
    this.numberList = numberList;
    return this;
  }

  public CallForwardingRulesGrid addNumberListItem(NumberOpenApiVo numberListItem) {
    if (this.numberList == null) {
      this.numberList = new ArrayList<>();
    }
    this.numberList.add(numberListItem);
    return this;
  }

  /**
   * Telephone numbers.
   * @return numberList
  */
  @ApiModelProperty(value = "Telephone numbers.")

  @Valid

  public List<NumberOpenApiVo> getNumberList() {
    return numberList;
  }

  public void setNumberList(List<NumberOpenApiVo> numberList) {
    this.numberList = numberList;
  }

  public CallForwardingRulesGrid deviceList(List<DeviceOpenApiVo> deviceList) {
    this.deviceList = deviceList;
    return this;
  }

  public CallForwardingRulesGrid addDeviceListItem(DeviceOpenApiVo deviceListItem) {
    if (this.deviceList == null) {
      this.deviceList = new ArrayList<>();
    }
    this.deviceList.add(deviceListItem);
    return this;
  }

  /**
   * Telephony devices.
   * @return deviceList
  */
  @ApiModelProperty(value = "Telephony devices.")

  @Valid

  public List<DeviceOpenApiVo> getDeviceList() {
    return deviceList;
  }

  public void setDeviceList(List<DeviceOpenApiVo> deviceList) {
    this.deviceList = deviceList;
  }

  public CallForwardingRulesGrid bookList(List<BookOpenApiVo> bookList) {
    this.bookList = bookList;
    return this;
  }

  public CallForwardingRulesGrid addBookListItem(BookOpenApiVo bookListItem) {
    if (this.bookList == null) {
      this.bookList = new ArrayList<>();
    }
    this.bookList.add(bookListItem);
    return this;
  }

  /**
   * Contacts.
   * @return bookList
  */
  @ApiModelProperty(value = "Contacts.")

  @Valid

  public List<BookOpenApiVo> getBookList() {
    return bookList;
  }

  public void setBookList(List<BookOpenApiVo> bookList) {
    this.bookList = bookList;
  }


  @Override
  public boolean equals(Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    CallForwardingRulesGrid callForwardingRulesGrid = (CallForwardingRulesGrid) o;
    return Objects.equals(this.totalRows, callForwardingRulesGrid.totalRows) &&
        Objects.equals(this.currentPage, callForwardingRulesGrid.currentPage) &&
        Objects.equals(this.currentSize, callForwardingRulesGrid.currentSize) &&
        Objects.equals(this.data, callForwardingRulesGrid.data) &&
        Objects.equals(this.numberList, callForwardingRulesGrid.numberList) &&
        Objects.equals(this.deviceList, callForwardingRulesGrid.deviceList) &&
        Objects.equals(this.bookList, callForwardingRulesGrid.bookList);
  }

  @Override
  public int hashCode() {
    return Objects.hash(totalRows, currentPage, currentSize, data, numberList, deviceList, bookList);
  }

  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class CallForwardingRulesGrid {\n");
    
    sb.append("    totalRows: ").append(toIndentedString(totalRows)).append("\n");
    sb.append("    currentPage: ").append(toIndentedString(currentPage)).append("\n");
    sb.append("    currentSize: ").append(toIndentedString(currentSize)).append("\n");
    sb.append("    data: ").append(toIndentedString(data)).append("\n");
    sb.append("    numberList: ").append(toIndentedString(numberList)).append("\n");
    sb.append("    deviceList: ").append(toIndentedString(deviceList)).append("\n");
    sb.append("    bookList: ").append(toIndentedString(bookList)).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    ");
  }
}

