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

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

import java.util.Objects;

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

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

  @JsonProperty("name")
  private String name;

  @JsonProperty("sourceIp")
  private String sourceIp;

  @JsonProperty("destination")
  private String destination;

  @JsonProperty("sourceLocation")
  private String sourceLocation;

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

  /**
   * Block list entry ID.
   * @return id
  */
  @ApiModelProperty(value = "Block list entry ID.")


  public String getId() {
    return id;
  }

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

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

  /**
   * The name of the defined blocked or isolated policy.
   * @return name
  */
  @ApiModelProperty(value = "The name of the defined blocked or isolated policy.")


  public String getName() {
    return name;
  }

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

  public IpsBlockListEntry sourceIp(String sourceIp) {
    this.sourceIp = sourceIp;
    return this;
  }

  /**
   * Source IP in defined blocked or isolated policy.
   * @return sourceIp
  */
  @ApiModelProperty(value = "Source IP in defined blocked or isolated policy.")


  public String getSourceIp() {
    return sourceIp;
  }

  public void setSourceIp(String sourceIp) {
    this.sourceIp = sourceIp;
  }

  public IpsBlockListEntry destination(String destination) {
    this.destination = destination;
    return this;
  }

  /**
   * The destination IP in defined blocked or isolated policy.
   * @return destination
  */
  @ApiModelProperty(value = "The destination IP in defined blocked or isolated policy.")


  public String getDestination() {
    return destination;
  }

  public void setDestination(String destination) {
    this.destination = destination;
  }

  public IpsBlockListEntry sourceLocation(String sourceLocation) {
    this.sourceLocation = sourceLocation;
    return this;
  }

  /**
   * The region code of the source IP.
   * @return sourceLocation
  */
  @ApiModelProperty(value = "The region code of the source IP.")


  public String getSourceLocation() {
    return sourceLocation;
  }

  public void setSourceLocation(String sourceLocation) {
    this.sourceLocation = sourceLocation;
  }


  @Override
  public boolean equals(Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    IpsBlockListEntry ipsBlockListEntry = (IpsBlockListEntry) o;
    return Objects.equals(this.id, ipsBlockListEntry.id) &&
        Objects.equals(this.name, ipsBlockListEntry.name) &&
        Objects.equals(this.sourceIp, ipsBlockListEntry.sourceIp) &&
        Objects.equals(this.destination, ipsBlockListEntry.destination) &&
        Objects.equals(this.sourceLocation, ipsBlockListEntry.sourceLocation);
  }

  @Override
  public int hashCode() {
    return Objects.hash(id, name, sourceIp, destination, sourceLocation);
  }

  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class IpsBlockListEntry {\n");
    
    sb.append("    id: ").append(toIndentedString(id)).append("\n");
    sb.append("    name: ").append(toIndentedString(name)).append("\n");
    sb.append("    sourceIp: ").append(toIndentedString(sourceIp)).append("\n");
    sb.append("    destination: ").append(toIndentedString(destination)).append("\n");
    sb.append("    sourceLocation: ").append(toIndentedString(sourceLocation)).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    ");
  }
}

